shime / vim-livedown

Vim plugin for Livedown.
493 stars 19 forks source link

Vim renames, not changes files #10

Closed androa closed 8 years ago

androa commented 9 years ago

There is an issue that falls between this Vim plugin, Vim itself and Livedown. A common Vim setup is that it creates a backupfile and replaces it in-place, resulting in a rename event instead of an change event.

shime commented 9 years ago

If I'm getting this straight - you are experiencing issue with updates when you save the file, is that right? Does calling :LivedownPreview still work? It's weird that Vim would issue a rename events for file changes - what version is this? Also, if there are some steps I can take to replicate this, it would help a lot.

androa commented 9 years ago

The initial view works, but subsequent changes on the does not trigger refreshes/updates over the socket (as the change event on the file is not fired).

This is a quite common issue when working with events and files written by vim, see this note in watchdogs documentation.

It can be circumvented by making vim write in-place, but it is usually done intentionally to not.

cdosborn commented 8 years ago

For any interested: set backupcopy=yes

shime commented 8 years ago

Thanks @cdosborn!

I'm closing this @androa, reopen if that doesn't fix the issue for you.