diff options
author | Christian Clason <c.clason@uni-graz.at> | 2025-04-04 10:15:21 +0200 |
---|---|---|
committer | Christian Clason <ch.clason+github@icloud.com> | 2025-04-04 10:43:18 +0200 |
commit | b788c7fa6cd4cce4cb3e1e8c6e900f1c95ce5218 (patch) | |
tree | db21e473a19a9db7dfb355ee567205fcc36a744d | |
parent | 74edfebbde4962ffd535f11d57a1ea0bc5322057 (diff) | |
download | rneovim-b788c7fa6cd4cce4cb3e1e8c6e900f1c95ce5218.tar.gz rneovim-b788c7fa6cd4cce4cb3e1e8c6e900f1c95ce5218.tar.bz2 rneovim-b788c7fa6cd4cce4cb3e1e8c6e900f1c95ce5218.zip |
vim-patch:6099db9: runtime(sh): Update syntax file, command substitution opening paren at EOL
Allow the opening parenthesis of a command substitution to appear at
EOL.
This fixes the issue raised in
https://github.com/vim/vim/issues/17026#issuecomment-2774112284.
closes: vim/vim#17044
https://github.com/vim/vim/commit/6099db9a60d1c047bf9c8feee3e1689c4e653250
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
-rw-r--r-- | runtime/syntax/sh.vim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/syntax/sh.vim b/runtime/syntax/sh.vim index 37d1c0a83c..298198274e 100644 --- a/runtime/syntax/sh.vim +++ b/runtime/syntax/sh.vim @@ -8,6 +8,7 @@ " 2025 Jan 06 add $PS0 to bashSpecialVariables (#16394) " 2025 Jan 18 add bash coproc, remove duplicate syn keywords (#16467) " 2025 Mar 21 update shell capability detection (#16939) +" 2025 Apr 03 command substitution opening paren at EOL (#17026) " Version: 208 " Former URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SH " For options and settings, please use: :help ft-sh-syntax @@ -389,7 +390,7 @@ syn match shEscape contained '\%(^\)\@!\%(\\\\\)*\\.' nextgroup=shComment " systems too, however, so the following syntax will flag $(..) as " an Error under /bin/sh. By consensus of vimdev'ers! if exists("b:is_kornshell") || exists("b:is_bash") || exists("b:is_posix") - syn region shCommandSub matchgroup=shCmdSubRegion start="\$(\ze[^(]" skip='\\\\\|\\.' end=")" contains=@shCommandSubList + syn region shCommandSub matchgroup=shCmdSubRegion start="\$((\@!" skip='\\\\\|\\.' end=")" contains=@shCommandSubList if exists("b:is_kornshell") syn region shSubshare matchgroup=shCmdSubRegion start="\${\ze[ \t\n<]" skip='\\\\\|\\.' end="\zs[ \t\n;]}" contains=@shCommandSubList syn region shValsub matchgroup=shCmdSubRegion start="\${|" skip='\\\\\|\\.' end="}" contains=@shCommandSubList |