From 074ca976decff1d9b49907fb2322f6493089d0f2 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Fri, 16 Jan 2026 07:27:27 +0800 Subject: [PATCH] vim-patch:16c2279: runtime(sh): highlight single-dash short options containing digits fixes: vim/vim#19082 https://github.com/vim/vim/commit/16c22790627f063981ce75ef3d4da1eb4f6bf8d0 Co-authored-by: Christian Brabandt --- runtime/syntax/sh.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/runtime/syntax/sh.vim b/runtime/syntax/sh.vim index 5cf4930658..382d6b177e 100644 --- a/runtime/syntax/sh.vim +++ b/runtime/syntax/sh.vim @@ -19,6 +19,7 @@ " 2025 Jul 18 properly delete :commands #17785 " 2025 Aug 23 bash: add support for ${ cmd;} and ${|cmd;} #18084 " 2025 Sep 23 simplify ksh logic, update sh statements #18355 +" 2026 Jan 15 highlight command switches that contain a digit " }}} " Version: 208 " Former URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SH @@ -345,7 +346,7 @@ endif " Options: {{{1 " ==================== -syn match shOption "\s\zs[-+][-_a-zA-Z#@]\+" +syn match shOption "\s\zs[-+][-_a-zA-Z#@0-9]\+" syn match shOption "\s\zs--[^ \t$=`'"|);]\+" " File Redirection Highlighted As Operators: {{{1