Editing a crontab with vim

If your vimrc is configured to use backup files and you try to invoke crontab -e (or vipw or visudo, etc.), you might get an error like this:

crontab: temp file must be edited in place

You need to make vim not do backups of temp files. An easy way to fix this is to add something like this to your vimrc file:

set backupskip=/tmp/*,/private/tmp/*

Thanks to http://vim.wikia.com/wiki/Editing_crontab

Leave a Reply

Your email address will not be published. Required fields are marked *