14
votes

Here's my error:

~> vim .tmux.conf 
Error detected while processing /Users/###/.spf13-vim-3/.vim/bundle/syntastic/plugin/syntastic.vim:
line   23:
E484: Can't open file /var/folders/c4/4nb5t7cs3wb17_g1w5030xc40000gn/T/vmIMCqB/0
Error detected while processing /Users/###/.spf13-vim-3/.vim/bundle/vim-preview/plugin/preview.vim:
line   94:
E484: Can't open file /var/folders/c4/4nb5t7cs3wb17_g1w5030xc40000gn/T/vmIMCqB/1
Press ENTER or type command to continue

I've checked those lines in each file and they both call system('uname'), which I'm unfamiliar with. I thought this error might have something to do with TERM (which is xterm-256color outside tmux and screen-256color inside), but changing this in the .tmux.conf has no effect.

This happens with any file.

I'm on Mac OS X 10.8.1, vim 7.3, tmux 1.6 and am using the fish shell.

1
Do these /var/… folders exist? Why is your .vim/ folder located in that ~/.spf13-vim-3 folder? Why would uname try to read the content of some random temporary folder? - romainl
Does running uname at the console generate a similar error? - Michael Schuller
Michael - uname prints "Darwin" - schellsan
Romani - /var exists, and after reading about the system() function I see that it executes a shell command and prints it to a temp file, then reads it back out...vimdoc.sourceforge.net/htmldoc/eval.html#system() - schellsan
Romani - also, spf13 is a customized vim distro (github.com/spf13/spf13-vim) - schellsan

1 Answers

31
votes

The problem is caused by the use of the fish shell as the default shell (set in my .tmux.conf). To solve the problem, add this to the top of your .vimrc file:

set shell=/bin/sh 

This post helped me sort things out:
Debian Bug report logs - #609599 vim-runtime: Error detected while processing ruby.vim.
Also thanks to commenters @MichaelSchuller and @romainl.