Is there a "vim runtime log"?
Put this function into .vimrc:
function! ToggleVerbose()
if !&verbose
set verbosefile=~/.log/vim/verbose.log
set verbose=15
else
set verbose=0
set verbosefile=
endif
endfunction
Then create directory ~/.log/vim
and call ToggleVerbose()
to get your log in ~/.log/vim/verbose.log
. Note that you may catch «variable nested too deep for displaying» error which will not normally appear just because you have raised your verbose level.
I don't think there is a runtime log, per se, but you can run it in debug mode.
http://web.archive.org/web/20090323034339/http://www.troubleshootingwiki.org/Debugging_Vim_Scripts
:messages
shows all warnings, errors, and informational messages that appeared (possibly briefly) in the vim statusline.
:echo errmsg
prints the most recent error message.
g<
is another feature few people know about. From :help g<
:
The
g<
command can be used to see the last page of previous command output. This is especially useful if you accidentally typed<Space>
at the hit-enter prompt.
For example try :!ls
then cancel the prompt, then hit g<
.
running vim with the -V[N] option will do a pretty hefty runtime log, here N is the debug level.
vim -V9myVim.log
would create a log of debug level 9 in the current directory with the filename myVim.log