I have a workflow where I edit a .org file using jceb/vim-orgmode which is located in my iCloud directory. I then have an app on my phone which also syncs and uses the same .org file. The problem is that iCloud will only sync the file when there are no open file handles referencing that file, so in order to sync I have to:

  1. edit
  2. :w
  3. :q
  4. wait for icloud to sync
  5. reopen the file

It would be great if there was a way for vim to only hold an open file for the duration of ":w", is this possible?

  • have a look and play with different values for the backupcopy option setting Sep 29, 2020 at 6:12
  • 1
    I don't know which OS you are on, but on Linux Vim doesn't keep an open file handle.
    – Ralf
    Sep 29, 2020 at 7:37


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.