Debugging Vim PlugIn Loading
I am using MacVim on OSX 10.6 and I started getting a strange error message when I open certain files and directories with vim
in the terminal. The vim
command is just a symlink to the mvim
script that comes with MacVim, and I am sure that I am running the MacVim binary, not the vim binary that ships with OSX.
The error meesage I get is E73: tag stack empty
.
This only happens when I open things with vim
. It doesn't happen when I use mvim
and open them in the gui version. Is there a way to turn on debug output or something for 开发者_开发问答vim so I can tell what line of code in which plugin is causing this?
-- additional information --
You can see the source of the mvim script, which launches MacVim from the command line, here: https://github.com/b4winckler/macvim/blob/snapshot-61/src/MacVim/mvim.
I installed MacVim with homebrew. Here's where all the files live:
$ which mvim
/usr/local/bin/mvim
$ which vim
/Users/mattcampbell/bin/vim
$ ls -lh `which vim`
lrwxr-xr-x 1 mattcampbell staff 19B Aug 22 18:36 /Users/mattcampbell/bin/vim -> /usr/local/bin/mvim
:help E73
suggests you are trying to use the tagstack.
:scriptnames
will show you which scripts you have loaded. Look to see if there's anything unexpected there.
If that doesn't turn up anything useful, use:
set verbose=20
...in your .vimrc
. This will give you a lot of information, so don't forget to reset it after you've fixed your issue.
精彩评论