Fix terminal detection
This commit is contained in:
parent
4f982ea624
commit
9d805e8b11
4
init.vim
4
init.vim
|
@ -8,7 +8,8 @@ runtime platform.vim
|
||||||
if g:platform ==? "linux"
|
if g:platform ==? "linux"
|
||||||
"autocmd VimLeave * set guicursor=a:ver35-blinkon0
|
"autocmd VimLeave * set guicursor=a:ver35-blinkon0
|
||||||
"set guicursor=
|
"set guicursor=
|
||||||
if $TERM ==? "alacritty"
|
let supported_terminals=["alacritty", "st-256color", "xterm-256color", "screen"]
|
||||||
|
if index(supported_terminals, $TERM) != -1
|
||||||
set termguicolors
|
set termguicolors
|
||||||
else
|
else
|
||||||
set notermguicolors
|
set notermguicolors
|
||||||
|
@ -19,6 +20,7 @@ elseif g:platform ==? "xterm"
|
||||||
set notermguicolors
|
set notermguicolors
|
||||||
set guicursor=
|
set guicursor=
|
||||||
set t_Co=
|
set t_Co=
|
||||||
|
autocmd ColorScheme dracula hi Visual cterm=reverse
|
||||||
else
|
else
|
||||||
set termguicolors
|
set termguicolors
|
||||||
endif
|
endif
|
||||||
|
|
Loading…
Reference in New Issue