I am forced to run this in my vim editor everytime I work.

highlight Normal ctermfg=grey ctermbg=black

What I want is for this to be automatic, I already have background set to dark but nothing is happening in vimrc. What should I do? Vimrc contents (first few lines)

syntax on
set background=dark
set ruler                     " show the line number on the bar
set more                      " use more prompt
set autoread                  " watch for file changes
set number                    " line numbers



In .vimrc, replace

set background=dark


highlight Normal ctermfg=grey ctermbg=black

If you make the changes permanently that you did in Vim then you have to write the code in .vimrc then open the .vimrc file and then place this line

set background=dark

and then save & close . then open the Vim and you will see the changes.


Notice that you can right-click on the terminal window - "Profiles" - "Profiles Preferences" - "Colors".

You can add it from .vimrc with set background=dark

Good luck

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.