[nvim] enable termguicolors if base16-shell is not loaded

This commit is contained in:
Dmytro Meleshko 2019-05-09 19:25:41 +03:00
parent a6241e3cd4
commit 8c5e2ca4b4
2 changed files with 4 additions and 6 deletions

View file

@ -5,12 +5,10 @@ let s:base16_theme_name = 'eighties'
" Color definitions {{{
let g:base16_shell_path = get(g:, 'base16_shell_path', expand('~/.zgen/chriskempson/base16-shell-master'))
let s:base16_shell_script = g:base16_shell_path . '/scripts/base16-' . s:base16_theme_name . '.sh'
if filereadable(s:base16_shell_script) && !&termguicolors
" call system(shellescape(s:base16_shell_script))
else
if empty($BASE16_SHELL) || !filereadable($BASE16_SHELL . '/scripts/base16-' . s:base16_theme_name . '.sh') || &termguicolors
set termguicolors
else
" call system(shellescape(s:base16_shell_script))
endif
" Eighties scheme by Chris Kempson (http://chriskempson.com)

View file

@ -9,7 +9,7 @@ done
command_exists rbenv && eval "$(rbenv init -)"
BASE16_SHELL="$HOME/.zgen/chriskempson/base16-shell-master"
export BASE16_SHELL="$HOME/.zgen/chriskempson/base16-shell-master"
BASE16_SHELL_profile_helper="$BASE16_SHELL/profile_helper.sh"
[[ -n "$PS1" && -r "$BASE16_SHELL_profile_helper" ]] && eval "$("$BASE16_SHELL_profile_helper")"