diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2019-07-11 15:10:29 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2019-07-11 15:10:29 +1200 |
commit | 805c023fab0f570d924ed5a9fa7b975aae2561de (patch) | |
tree | 7414b044537765df3ba1d20fdbd90121208ca7b8 | |
parent | Merge branch 'release/v6.54.0' (diff) | |
parent | Bump VERSION (diff) | |
download | dotfiles-6.55.0.tar.gz (sig) dotfiles-6.55.0.zip |
Merge branch 'release/v6.55.0'v6.55.0
* release/v6.55.0:
Avoid let-& syntax
-rw-r--r-- | VERSION | 4 | ||||
-rw-r--r-- | vim/autoload/colorscheme.vim | 8 | ||||
-rw-r--r-- | vim/vimrc | 11 |
3 files changed, 14 insertions, 9 deletions
@@ -1,2 +1,2 @@ -tejr dotfiles v6.54.0 -Tue, 09 Jul 2019 02:43:28 +0000 +tejr dotfiles v6.55.0 +Thu, 11 Jul 2019 03:10:27 +0000 diff --git a/vim/autoload/colorscheme.vim b/vim/autoload/colorscheme.vim new file mode 100644 index 00000000..9ee9f24d --- /dev/null +++ b/vim/autoload/colorscheme.vim @@ -0,0 +1,8 @@ +" Reset colorscheme based on current colorscheme name +function! colorscheme#UpdateCursorline(colors_name, list) abort + if index(a:list, a:colors_name) >= 0 + set cursorline + else + set nocursorline + endif +endfunction @@ -323,7 +323,7 @@ endif set spellfile& execute 'set spellfile^='.escape#Arg(escape#Item(s:spellfile)) if exists('s:isfname') - let &isfname = s:isfname + execute 'set isfname='.escape#Arg(s:isfname) unlet s:isfname endif CreatePath $MYVIM/spell @@ -439,11 +439,8 @@ set smarttab " " <https://github.com/vim/vim/releases/tag/v7.3.693> " -if has#('patch-7.3.693') - set softtabstop=-1 -else - let &softtabstop = &shiftwidth -endif +execute 'set softtabstop=' + \ . escape#Arg(has#('patch-7.3.693') ? -1 : &shiftwidth) " Relax traditional vi’s harsh standards over what regions of the buffer can " be removed with backspace in insert mode. While this admittedly allows bad @@ -916,7 +913,7 @@ endif " <https://github.com/vim/vim/releases/tag/v7.4.108> " autocmd vimrc ColorScheme * - \ let &cursorline = g:colors_name ==# 'sahara' + \ call colorscheme#UpdateCursorline(g:colors_name, ['sahara']) " Use 'dark' as my default value for 'background', in the absence of an " environment variable COLORFGBG or a response in v:termrbgresp that would set |