Question

I was wondering how can I make vim custom colorschemes to work in tty terminals with 8 colors (the ctrl+alt+fx one).

I'm using molokai theme for vim (code here)

Right now, when I open vim in tty, it appears only as light blue instead of 8 colors, if I select molokai..

It was working yesterday, but I think I changed some file and I messed it up.

So, tell me please what should I do to fix this.

Thanks in advance!

PS: I don't keep every file under git. So probably I erased something which was not.

Was it helpful?

Solution

You'll need to duplicate the "256 colors" block:

if &t_Co > 255
    " color definitions
endif

in order to create an "8 colors" block:

if &t_Co == 8
    " color definitions
endif

and edit every color value in that new block according to :h cterm-colors.

Good luck.

OTHER TIPS

This might not be the best answer, but since you are, wisely, using revision control, why don't you do :

git diff <working-commit> <non-working commit>

You can even do a git bisect, and find the issue by yourself ?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top