Skip to content

soft link for main file directory fails silently (linux edition) #5664

@jamesp670

Description

@jamesp670

JabRef version on

Steps to reproduce the behavior:

We commence with a bibtex entry Gurney2019 and ~/papers/Gurney2019.
The entry doesn't link to the PDF.

  1. Go to Options/Preferences/File.
  2. set path to /home/powellj/papers (the soft link)
  3. Make sure there's no file link for Gurney2019, remove it if there
    is.
  4. Pick Quality/Automatically set file links (F7)

It finishes quickly with no error. No file link has been made for
Gurney2019 in jabref. No error was printed, but the PDF is in the directory i indicated.
This is a bug, and it happens because /home/powellj/papers is a Unix soft link to the true directory.
If jabref can't follow the soft link (?) then an error message is needed.

Next, use a path that doesn't have a soft link and you get very different behavior.

  1. Go to Options/Preferences/File.
  2. set "main file directory" to
    : /home/powellj/meow-backups/jep-files-current-total/meow/jep-files/research/papers
    (the directory pointed to by /home/powellj/papers)
  3. Pick Quality/Automatically set file links (F7)

It finishes quickly with no error. This time Gurney2019.pdf was found and the
file link has been made for Gurney2019.

Please support a soft link for the main file directory. I put this in
as a bug because I pick a perfectly good directory (in the Unix idiom
the fact that it's a soft link should be invisible to the app), and
not only do not get the desired result but the failure is silent. At
the very least if you can't open the link and read it as a directory
this should be detected and immediately reported to the user through a
modal dialog saying "Warning: you have selected a non-directory for
the main file directory. Jabref will not find files there."

Thank you for everything you do, I heart jabref bigtime but this hang-up has plagued my work flow for years. I use links heavily to keep paths short and legible and flexible: my papers are sometimes on a thumb drive at /media/powellj, sometimes on a different drive, and I change the link auromatically as they move - I do this daily to move files from home to work and I like it that way: this is a solid use case for supporting soft links.

Log File
Paste an excerpt of your log file here

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions