Skip to content

Commit fe8cc63

Browse files
committed
fixup! Ticket #4715: fix basic heredoc highlighting for shell syntax
Signed-off-by: Yury V. Zaytsev <[email protected]>
1 parent 028f2b1 commit fe8cc63

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

misc/syntax/sh.syntax

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1093,7 +1093,8 @@ context # \n brown
10931093

10941094
context ' ' green
10951095

1096-
# Basic support for heredocs with suppressed variable expansion ('exclusive' keyword breaks the matching)
1096+
# Basic support for heredocs with suppressed variable expansion: 'exclusive' keyword breaks the matching due
1097+
# to a conflict with the rules for quotes, so remove it in all cases, including `\`, for consistency.
10971098
wholechars abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'"\\
10981099
context whole <<\[\s\]\[-\]\[\s\]\\EOF EOF green
10991100
context whole <<\[\s\]\[-\]\[\s\]\\END END green
@@ -1127,7 +1128,7 @@ context " " green
11271128
keyword $ brightgreen
11281129

11291130
# Basic support for heredocs with variable expansion
1130-
context whole <<\[\s\]\[-\]\[\s\]EOF EOF green
1131+
context exclusive whole <<\[\s\]\[-\]\[\s\]EOF EOF green
11311132
keyword \\* brightgreen
11321133
keyword \\@ brightgreen
11331134
keyword \\$ brightgreen
@@ -1150,7 +1151,7 @@ context whole <<\[\s\]\[-\]\[\s\]EOF EOF green
11501151

11511152
keyword $ brightgreen
11521153

1153-
context whole <<\[\s\]\[-\]\[\s\]END END green
1154+
context exclusive whole <<\[\s\]\[-\]\[\s\]END END green
11541155
keyword \\* brightgreen
11551156
keyword \\@ brightgreen
11561157
keyword \\$ brightgreen

0 commit comments

Comments
 (0)