Vim startup errors (invalid expression) Debian

Oh my gosh! I see several issues:

E492: Not an editor command: generate helptags for everything in 'runtimepath'

You must have a line starting with generate helptags ... somewhere (your ~/.vimrc?); it should be a comment: Prepend a " to the line.


***** L9 library must be installed! *****

The FuzzyFinder plugin requires another plugin; you can get it at L9 - Vim-script library.


Error detected while processing /home/lee/.vim/plugin/refactor.vim:
line   45:
E492: Not an editor command: ^M

That's caused by Vimscript files that have Windows-style CR-LF line endings when used on Linux. Open the corresponding file(s) in Vim and convert them to Unix-style endings via

:w ++ff=unix

I hope you'll start to see the light after these. A link to your full Vim config would be helpful to further diagnose this. If you're new to Vim, it's recommended to start with a lean .vimrc, and only gradually add plugins, as you become more proficient and identify the needs.


For the E492: Not an editor command: ^M part, I actually got the same problem but the above answers didn't help. So I found this and it works for me:

For Cygwin (which I use): install dos2unix from the package installer

For Ubuntu/Debian:

sudo apt-get install tofrodos; sudo ln -s /usr/bin/fromdos /usr/bin/dos2unix

For CentOS, Fedora, ...:

sudo yum install dos2unix

Then use it this way:

dos2unix ~/.vimrc

That should clean all CRLF from the file

Tags:

Vim

Debian