Every time I write a new python source code *.py
, the following error message comes up:
Error detected while processing BufRead Auto commands for"*.py":
E518:Unknow option:set
E28:No such highlight group name: BadWhitespace
How can I fix it?
Before I typed this question , I modified my _vimrc
file according to this post, but the error message remains. Even worse another error message occurs as well:
The ycmd server SHUT DOWN(restart with':YcmRestartSever').YCM core library not detected;you need to compile YCM before using it. Follow the instructions in the documentation.
I am a new Gvim user and I use gVim 8.0 in Windows 10. I set up my python development environment by searching the Internet and I installed the YouCompleteMe plugin via Vundle but It is too difficult for me to compile YCM myself now.
_vimrc
file. – Juanjuanamatch
command applies a "highlight group" (which is a set of background and/or foreground colours), in your caseBadWhitespace
to strings matching the supplied pattern. Your problem is that you don't have this this highlight group defined (you probably didn't paste the whole snippet from the article). To fix it, you have to define the highlight group with something likehighlight BadWhitespace ctermbg=red guibg=red
in your _vimrc. This will instruct vim thatBadWhitespace
means it should colour the background red. The colour can be either a noun or a hex code like,#6f4822
. – Juanjuana_vimrc
(or rather a minimal, complete, verifiable snippet that reproduces the problem). – Juanjuana