Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

vim and skim file update

Tags:

vim

skim

I have a MacBook and I am writing a latex file in vim and I render to created pdf in Skim. I have setup Skim to check for file changes. Every time I save my latex file, I get an error from Skim that says: "Unable to load file". The file is still loaded correctly, so I am not sure why I am getting this error. Is there something that I need to do in order not to get this error?

like image 673
P. Khoza Avatar asked May 20 '26 14:05

P. Khoza


1 Answers

This may be related to the way that Vim is writing the buffer. With the default value of 'backupcopy', Vim renames the original file, and then writes a new one with the updated contents. Other applications that observe the original file for changes might get confused about that, resulting in that error you see.

Try :setlocal backupcopy=yes. If that gets rid of the error, you can define this globally (with :set) in your ~/.vimrc, or just for Latex files via the corresponding :help ftplugin-overrule.

like image 177
Ingo Karkat Avatar answered May 22 '26 07:05

Ingo Karkat



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!