简体   繁体   中英

vim and skim file update

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?

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 .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM