jabref icon indicating copy to clipboard operation
jabref copied to clipboard

Enhancements to handling of externally modified files

Open khatchad opened this issue 3 years ago • 1 comments

I'm always frustrated when I issue a git pull on the command line that changes the .bib file already opened in JabRef. I see there is a warning about the file being externally altered and asking me whether I want to review it. However, I often ignore this warning as:

  • [x] 1. It tends to pop up even when there are no external file changes.
    • [x] largely fixed by #9067
    • [ ] #9064 remains, but this edge-case is very unlikely to trigger in a normal workflow.
  • [x] 2. It crashes when I do review the external changes.
  • [ ] 3. I don't have time to review them.

What's worse is that when I ignore the warning and make changes to the older version of the file in memory, the newer data gets overwritten. Then, I have to undo my new changes, reload the file in JabRef, and make the new changes again.

I wish this feature worked more like autoread in Vim where external file changes are automatically read from disk into the open buffer. The exception would be when I have unsaved changes open and the file changes underneath. Then, perhaps a review option would be advantageous.

khatchad avatar Jan 15 '22 22:01 khatchad

Hi,

yes this is a known problem that the change detection and our saving/backup strategy currently have issues. We are aware of this and try to come up with a solution. For the review crash, try out the latest development version. That issue has been fixed there.

Siedlerchr avatar Jan 16 '22 12:01 Siedlerchr

Some links to related issues:

In https://github.com/JabRef/jabref/blob/main/docs/code-howtos/remote-storage-jabdrive.md we desribe our synchronization algorithm with remote storages. Maybe, this also helps to resolve this issue.

At https://github.com/JabRef/jabref/pull/5669, I began with an implementation solving that issue.

koppor avatar May 21 '23 03:05 koppor

Related issue: https://github.com/koppor/jabref/issues/578

koppor avatar Mar 05 '24 10:03 koppor