Utility program for converting vim colorschemes to GNOME Terminal colors
key=value
background, foreground, bold, black, lblack, red, lred, green, lgreen, yellow, lyellow,
blue, lblue, cyan, lcyan, purple, lpurple, white, lwhite
For pairs [colorname] and l[colorname] at leas one of the two must be set. If one of them is missing color value is calculate from the other (10% darker than light color or 10% lighter than normal color)
There are two supported value formats:
-
Color in hexadecimal notation (#000000)
-
Color name from vim colorscheme
let [a-z]+:%s *= *\"(#[0-9a-fA-F]{6})\"
$ python terminalcolors.py path/to/mapping/file path/to/vim/colorscheme
If successful, new profile with colors set will be avaliable in Gnome Terminal
To see if all the colors are mapped correctly run:
$ ./colortest.sh
Conversion of vim coloscheme hybrid
background=background
foreground=foreground
bold=aqua
black=#000000
lblack=#666666
red=red
green=green
yellow=yellow
blue=blue
cyan=aqua
purple=purple
white=#929395
$ python terminalcolors.py color_mapping path/to/hybrid.vim