Set termguicolors in vimrc when available

This commit is contained in:
Lynda Wang 2020-07-25 16:38:58 -04:00
parent 5054aecda5
commit ee11695dee
2 changed files with 10 additions and 2 deletions

8
vimrc
View File

@ -37,6 +37,13 @@ endfunction
"--------------------------------------------
" Colors
"--------------------------------------------
if has('termguicolors')
set termguicolors
" Set Vim-specific sequences for RGB colors
let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
endif
let g:campo_dark_theme = 'campo-simple-dark'
"let g:campo_dark_theme = 'campo-dark-blue'
"let g:campo_dark_theme = 'campo-dark-grey-blue'
@ -282,6 +289,7 @@ set backspace=indent,eol,start " Allow backspacing over everything in insert
set complete+=kspell " Spell checking autocomplete.
set complete-=i " Don't scan all included files since it's really slow.
set termguicolors
syntax on " Enable highlighting for syntax
set wildmenu

4
zshrc
View File

@ -90,8 +90,8 @@ bindkey -e
source $ZSH/lib/*.zsh
# Source my custom files after oh-my-zsh so I can override things.
source $HOME/.dotfiles/functions
source $HOME/.dotfiles/aliases
source $HOME/.env.platform
source $HOME/.aliases
# Fix <c-h> in neovim
infocmp $TERM | sed 's/kbs=^[hH]/kbs=\\177/' > $HOME/.$TERM.ti