[sh] Allow hyphens in variables but not every character

Co-Authored-By: Frank LENORMAND <lenormf@gmail.com>
This commit is contained in:
Lennard Hofmann 2020-01-15 13:56:25 +00:00 committed by GitHub
parent b84d852723
commit 71e4ac4574
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -55,7 +55,7 @@ evaluate-commands %sh{
} }
add-highlighter shared/sh/code/operators regex [\[\]\(\)&|]{1,2} 0:operator add-highlighter shared/sh/code/operators regex [\[\]\(\)&|]{1,2} 0:operator
add-highlighter shared/sh/code/variable regex (\S+)= 1:variable add-highlighter shared/sh/code/variable regex ([\w-]+)= 1:variable
add-highlighter shared/sh/code/function regex ^\h*(\w+)\h*\(\) 1:function add-highlighter shared/sh/code/function regex ^\h*(\w+)\h*\(\) 1:function
add-highlighter shared/sh/code/unscoped_expansion regex \$(\w+|#|@|\?|\$|!|-|\*) 0:value add-highlighter shared/sh/code/unscoped_expansion regex \$(\w+|#|@|\?|\$|!|-|\*) 0:value