From 388081f881656dece4388ba448713b9f2f062905 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Wed, 8 Nov 2017 12:51:30 +1300 Subject: Disable unwanted shell error syntax for any shell --- vim/after/syntax/sh.vim | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/vim/after/syntax/sh.vim b/vim/after/syntax/sh.vim index 930255fc..48a3452d 100644 --- a/vim/after/syntax/sh.vim +++ b/vim/after/syntax/sh.vim @@ -9,19 +9,14 @@ elseif exists('b:is_posix') unlet! b:is_sh endif -" Some corrections for highlighting if we have any of POSIX, Bash, or Ksh -if exists('g:is_posix') || exists('b:is_bash') || exists('b:is_ksh') +" The syntax highlighter seems to flag '/baz' in '"${foo:-"$bar"/baz}"' as an +" error, which it isn't, at least in POSIX sh, Bash, and Ksh. +syntax clear shDerefWordError - " The syntax highlighter seems to flag '/baz' in '"${foo:-"$bar"/baz}"' as an - " error, and I'm pretty sure it's not, at least in POSIX sh, Bash, and Ksh. - syntax clear shDerefWordError - - " The syntax highlighter doesn't match parens for subshells for 'if' tests - " correctly if they're on separate lines. This happens enough that it's - " probably not worth keeping the error. - syntax clear shParenError - -endif +" The syntax highlighter doesn't match parens for subshells for 'if' tests +" correctly if they're on separate lines. This happens enough that it's +" probably not worth keeping the error. +syntax clear shParenError " Some corrections for highlighting specific to the Bash mode if exists('b:is_bash') -- cgit v1.2.3