Skip to content

Commit 272a308

Browse files
authored
Merge pull request micro-editor#3663 from niten94/sh-separate-paramexp
`sh.yaml`: Match valid parameter expansions without braces
2 parents c937479 + 0985d2c commit 272a308

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

runtime/syntax/sh.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ rules:
4141
# Conditional flags
4242
- statement: "\\s+(-[A-Za-z]+|--[a-z]+)"
4343

44-
- identifier: "\\$\\{[0-9A-Za-z_:!%&=+#~@*^$?, .\\-\\/\\[\\]]+\\}"
45-
- identifier: "\\$[0-9A-Za-z_:!%&=+#~@*^$?,\\-\\[\\]]+"
44+
- identifier: "\\$\\{[\\w:!%&=+#~@*^$?, .\\-\\/\\[\\]]+\\}"
45+
- identifier: "\\$([0-9_!#@*$?-]|[A-Za-z_]\\w*)"
4646

4747
- constant.string:
4848
start: "\""

0 commit comments

Comments
 (0)