Closed wis closed 3 years ago
does the other vim instance write a swap file?
btw, does resetting the shortmess
option change anything?
does the other vim instance write a swap file?
yes, the first instance creates it
btw, does resetting the shortmess option change anything?
no, I appended set shortmess=
to my init.vim and tried again, same thing happens, a swap file get created first time I open file, and a second time when it doesn't warn and shows content after a barely noticeable pause.
yes, the first instance creates it
In the same location?
So does this only happen in Neovim or also in Vim.
Same problem here on Neovim 0.4.3.
In the same location?
By default Neovim stores all swap files in the ~/.local/share/nvim/swap/
dir.
@selurvedu That explains! For all this time I was oblivious of the notes I am losing until today when I had to go through the old ones. @chrisbra You might want to add the warning for neovim users. Also, any other similar plugins meanwhile?
Hm, so let me summarize:
1) You open the file in Vim, do some changes and Vim creates the swapfile as usual in the current directory. 2) You open the same file in Neovim, but you do not get the warning message with the compare prompt.
That is, because Neovim creates the swapfile ~/.local/share/nvim/swap/
and does not care about the swapfile in the current directory?. Is this right?
I can add a message in the documentation, not sure this will help much. I guess it makes sense, to configure both Vim and Neovim to use the same directory for swap files, so correctly setting the 'dir' option.
Hey, thank you for creating this immensely useful plugin :smiley:
I just noticed that the message stopped showing even though I have the file opened in an other vim process.
I tried to isolate the issue, so here's what I've done:
for my init.vim: uncommented all other vimplug loading lines of all the other plugins and kept only this one, the issue persists. feels like something's happening in the background, but vim stays blank for a little while until the file content appears
tested in vim, and couldn't get the "Compare" option to show in the message: $
/usr/bin/vim -u testvimrc testfile
testvimrc:call plug#begin('~/.vim/plugged') Plug 'chrisbra/Recover.vim' call plug#end()