github-linguist 5.0.11 → 5.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/grammars/source.antlr.json +2 -2
- data/grammars/source.batchfile.json +31 -39
- data/grammars/source.c++.json +2 -2
- data/grammars/source.c.json +1 -1
- data/grammars/source.capnp.json +2 -2
- data/grammars/source.chapel.json +2 -2
- data/grammars/source.clojure.json +3 -1
- data/grammars/source.coffee.json +6 -6
- data/grammars/source.crystal.json +1 -1
- data/grammars/source.csound-document.json +20 -5
- data/grammars/source.csound-score.json +1 -1
- data/grammars/source.csound.json +7 -20
- data/grammars/source.css.less.json +2 -2
- data/grammars/source.cython.json +2 -2
- data/grammars/source.dart.json +16 -20
- data/grammars/source.ditroff.json +3 -3
- data/grammars/source.elixir.json +3 -3
- data/grammars/source.erlang.json +1 -1
- data/grammars/source.fan.json +345 -0
- data/grammars/source.fancy.json +1 -1
- data/grammars/source.gdb.json +1 -1
- data/grammars/source.gdb.session.json +1 -1
- data/grammars/source.gdscript.json +1 -1
- data/grammars/source.gfm.json +16 -0
- data/grammars/source.grace.json +1 -1
- data/grammars/source.harbour.json +1 -1
- data/grammars/source.idl.json +1 -1
- data/grammars/source.java.json +2 -2
- data/grammars/source.jison.json +45 -7
- data/grammars/source.jisonlex.json +13 -3
- data/grammars/source.js.json +7 -7
- data/grammars/source.js.regexp.json +2 -2
- data/grammars/source.jsdoc.json +24 -49
- data/grammars/source.livescript.json +4 -4
- data/grammars/source.logtalk.json +1 -1
- data/grammars/source.lsl.json +1 -1
- data/grammars/source.lua.json +5 -7
- data/grammars/source.mask.json +2 -2
- data/grammars/source.nim.json +2 -2
- data/grammars/source.nim_filter.json +2 -2
- data/grammars/source.nimcfg.json +2 -2
- data/grammars/source.nix.json +2 -2
- data/grammars/source.nu.json +2 -2
- data/grammars/source.pan.json +711 -0
- data/grammars/source.pawn.json +1 -1
- data/grammars/source.perl6fe.json +384 -7
- data/grammars/source.php.zephir.json +2 -2
- data/grammars/source.reason.json +2 -2
- data/grammars/source.ring.json +277 -0
- data/grammars/source.rust.json +8 -3
- data/grammars/source.scad.json +2 -2
- data/grammars/source.shell.json +1 -1
- data/grammars/source.smalltalk.json +83 -16
- data/grammars/source.spin.json +2 -2
- data/grammars/source.sqf.json +1 -1
- data/grammars/source.supercollider.json +2 -2
- data/grammars/source.swift.json +41 -2
- data/grammars/source.tl.json +264 -0
- data/grammars/source.toml.json +3 -3
- data/grammars/source.vhdl.json +1 -1
- data/grammars/source.webassembly.json +344 -0
- data/grammars/source.yaml.json +2 -2
- data/grammars/text.haml.json +3 -3
- data/grammars/text.html.handlebars.json +17 -8
- data/grammars/text.html.markdown.source.gfm.mson.json +1 -1
- data/grammars/text.html.php.blade.json +987 -440
- data/grammars/text.html.php.json +6 -6
- data/grammars/text.html.soy.json +3 -3
- data/grammars/text.html.vue.json +10 -10
- data/grammars/text.marko.json +3 -3
- data/grammars/text.roff.json +6 -3
- data/lib/linguist/heuristics.rb +4 -4
- data/lib/linguist/languages.json +1 -1
- data/lib/linguist/languages.yml +54 -4
- data/lib/linguist/samples.json +3030 -470
- data/lib/linguist/vendor.yml +3 -0
- data/lib/linguist/version.rb +1 -1
- metadata +7 -2
@@ -121,7 +121,7 @@
|
|
121
121
|
"name": "string.quoted.script.livescript",
|
122
122
|
"patterns": [
|
123
123
|
{
|
124
|
-
"match": "\\\\(x
|
124
|
+
"match": "\\\\(x[0-9A-Fa-f]{2}|[0-2][0-7]{0,2}|3[0-6][0-7]|37[0-7]?|[4-7][0-7]?|.)",
|
125
125
|
"name": "constant.character.escape.livescript"
|
126
126
|
}
|
127
127
|
]
|
@@ -154,7 +154,7 @@
|
|
154
154
|
"name": "string.regexp.livescript",
|
155
155
|
"patterns": [
|
156
156
|
{
|
157
|
-
"match": "\\\\(x
|
157
|
+
"match": "\\\\(x[0-9A-Fa-f]{2}|[0-2][0-7]{0,2}|3[0-6][0-7]|37[0-7]?|[4-7][0-7]?|.)",
|
158
158
|
"name": "constant.character.escape.livescript"
|
159
159
|
},
|
160
160
|
{
|
@@ -482,7 +482,7 @@
|
|
482
482
|
"name": "string.quoted.double.livescript",
|
483
483
|
"patterns": [
|
484
484
|
{
|
485
|
-
"match": "\\\\(x
|
485
|
+
"match": "\\\\(x[0-9A-Fa-f]{2}|[0-2][0-7]{0,2}|3[0-6][0-7]|37[0-7]?|[4-7][0-7]?|.)",
|
486
486
|
"name": "constant.character.escape.livescript"
|
487
487
|
},
|
488
488
|
{
|
@@ -590,7 +590,7 @@
|
|
590
590
|
"name": "string.quoted.single.livescript",
|
591
591
|
"patterns": [
|
592
592
|
{
|
593
|
-
"match": "\\\\(x
|
593
|
+
"match": "\\\\(x[0-9A-Fa-f]{2}|[0-2][0-7]{0,2}|3[0-6][0-7]?|37[0-7]?|[4-7][0-7]?|.)",
|
594
594
|
"name": "constant.character.escape.livescript"
|
595
595
|
}
|
596
596
|
]
|
data/grammars/source.lsl.json
CHANGED
data/grammars/source.lua.json
CHANGED
@@ -3,9 +3,7 @@
|
|
3
3
|
"fileTypes": [
|
4
4
|
"lua",
|
5
5
|
"p8",
|
6
|
-
"rockspec"
|
7
|
-
"luacheckrc",
|
8
|
-
"lakefile"
|
6
|
+
"rockspec"
|
9
7
|
],
|
10
8
|
"firstLineMatch": "\\A#!.*?\\blua(\\d+(\\.\\d+)?)?\\b|\\A--\\s+-\\*-\\s*lua\\s*-\\*-",
|
11
9
|
"keyEquivalent": "^~L",
|
@@ -42,11 +40,11 @@
|
|
42
40
|
]
|
43
41
|
},
|
44
42
|
{
|
45
|
-
"match": "(?<![\\w\\d.])0[xX]
|
43
|
+
"match": "(?<![\\w\\d.])0[xX][0-9A-Fa-f]+(?![pPeE.0-9])",
|
46
44
|
"name": "constant.numeric.integer.hexadecimal.lua"
|
47
45
|
},
|
48
46
|
{
|
49
|
-
"match": "(?<![\\w\\d.])0[xX]
|
47
|
+
"match": "(?<![\\w\\d.])0[xX][0-9A-Fa-f]+(\\.[0-9A-Fa-f]+)?([eE]-?\\d*)?([pP][-+]\\d+)?",
|
50
48
|
"name": "constant.numeric.float.hexadecimal.lua"
|
51
49
|
},
|
52
50
|
{
|
@@ -260,11 +258,11 @@
|
|
260
258
|
"name": "constant.character.escape.byte.lua"
|
261
259
|
},
|
262
260
|
{
|
263
|
-
"match": "\\\\x
|
261
|
+
"match": "\\\\x[0-9A-Fa-f][0-9A-Fa-f]",
|
264
262
|
"name": "constant.character.escape.byte.lua"
|
265
263
|
},
|
266
264
|
{
|
267
|
-
"match": "\\\\u\\{
|
265
|
+
"match": "\\\\u\\{[0-9A-Fa-f]+\\}",
|
268
266
|
"name": "constant.character.escape.unicode.lua"
|
269
267
|
},
|
270
268
|
{
|
data/grammars/source.mask.json
CHANGED
@@ -329,7 +329,7 @@
|
|
329
329
|
]
|
330
330
|
},
|
331
331
|
"klass_id": {
|
332
|
-
"begin": "([\\.#][\\w_
|
332
|
+
"begin": "([\\.#][\\w_\\-$:]*)",
|
333
333
|
"beginCaptures": {
|
334
334
|
"1": {
|
335
335
|
"name": "entity.other.attribute-name.markup.bold.mask"
|
@@ -652,7 +652,7 @@
|
|
652
652
|
]
|
653
653
|
},
|
654
654
|
"tag_javascript": {
|
655
|
-
"begin": "(slot|event|function|script)\\b",
|
655
|
+
"begin": "(slot|pipe|event|function|script)\\b",
|
656
656
|
"beginCaptures": {
|
657
657
|
"1": {
|
658
658
|
"name": "support.constant"
|
data/grammars/source.nim.json
CHANGED
@@ -228,7 +228,7 @@
|
|
228
228
|
},
|
229
229
|
{
|
230
230
|
"comment": "A hexadecimal literal",
|
231
|
-
"match": "(?<![\\w\\x{80}-\\x{10FFFF}])(0[xX]
|
231
|
+
"match": "(?<![\\w\\x{80}-\\x{10FFFF}])(0[xX][0-9A-Fa-f][_0-9A-Fa-f]*)('?(([iIuUfF](8|16|32|64))|[uUfFdD]))?",
|
232
232
|
"name": "constant.numeric.integer.hexadecimal.nim"
|
233
233
|
},
|
234
234
|
{
|
@@ -1169,7 +1169,7 @@
|
|
1169
1169
|
"name": "constant.character.escape.escape.nim"
|
1170
1170
|
},
|
1171
1171
|
{
|
1172
|
-
"match": "\\\\[xX]
|
1172
|
+
"match": "\\\\[xX][0-9A-Fa-f]{2}",
|
1173
1173
|
"name": "constant.character.escape.hex.nim"
|
1174
1174
|
},
|
1175
1175
|
{
|
@@ -19,7 +19,7 @@
|
|
19
19
|
"name": "constant.numeric.float.decimal.nim_filter"
|
20
20
|
},
|
21
21
|
{
|
22
|
-
"match": "\\b(0[xX]
|
22
|
+
"match": "\\b(0[xX][0-9A-Fa-f][_0-9A-Fa-f]*)('[iIuU](8|16|32|64))?",
|
23
23
|
"name": "constant.numeric.integer.hexadecimal.nim_filter"
|
24
24
|
},
|
25
25
|
{
|
@@ -114,7 +114,7 @@
|
|
114
114
|
"name": "string.quoted.double.nim_filter",
|
115
115
|
"patterns": [
|
116
116
|
{
|
117
|
-
"match": "(\\\\([abenrclftv]|[\"']|[0-9])|x
|
117
|
+
"match": "(\\\\([abenrclftv]|[\"']|[0-9])|x[0-9A-Fa-f]{2})"
|
118
118
|
}
|
119
119
|
]
|
120
120
|
},
|
data/grammars/source.nimcfg.json
CHANGED
@@ -46,7 +46,7 @@
|
|
46
46
|
"name": "constant.numeric.float.decimal.nimcfg"
|
47
47
|
},
|
48
48
|
{
|
49
|
-
"match": "\\b(0[xX]
|
49
|
+
"match": "\\b(0[xX][0-9A-Fa-f][_0-9A-Fa-f]*)('[iIuU](8|16|32|64))?",
|
50
50
|
"name": "constant.numeric.integer.hexadecimal.nimcfg"
|
51
51
|
},
|
52
52
|
{
|
@@ -90,7 +90,7 @@
|
|
90
90
|
"name": "string.quoted.double.nimcfg",
|
91
91
|
"patterns": [
|
92
92
|
{
|
93
|
-
"match": "(\\\\([abenrclftv\\\\]|[\"']|[0-9])|x
|
93
|
+
"match": "(\\\\([abenrclftv\\\\]|[\"']|[0-9])|x[0-9A-Fa-f]{2})"
|
94
94
|
}
|
95
95
|
]
|
96
96
|
},
|
data/grammars/source.nix.json
CHANGED
@@ -354,7 +354,7 @@
|
|
354
354
|
]
|
355
355
|
},
|
356
356
|
"bad-reserved": {
|
357
|
-
"match": "\\
|
357
|
+
"match": "(?<![\\w'-])(if|then|else|assert|with|let|in|rec|inherit)(?![\\w'-])",
|
358
358
|
"name": "invalid.illegal.reserved.nix"
|
359
359
|
},
|
360
360
|
"comment": {
|
@@ -1181,7 +1181,7 @@
|
|
1181
1181
|
"match": "\\s+"
|
1182
1182
|
},
|
1183
1183
|
"with-assert": {
|
1184
|
-
"begin": "\\
|
1184
|
+
"begin": "(?<![\\w'-])(with|assert)(?![\\w'-])",
|
1185
1185
|
"beginCaptures": {
|
1186
1186
|
"0": {
|
1187
1187
|
"name": "keyword.other.nix"
|
data/grammars/source.nu.json
CHANGED
@@ -27,7 +27,7 @@
|
|
27
27
|
"name": "punctuation.definition.constant.nu"
|
28
28
|
}
|
29
29
|
},
|
30
|
-
"match": "(')(.|\\\\[nrfbaes]|\\\\[0-7]{3}|\\\\x
|
30
|
+
"match": "(')(.|\\\\[nrfbaes]|\\\\[0-7]{3}|\\\\x[0-9A-Fa-f]{2}|\\\\u[0-9A-Fa-f]{4})(')",
|
31
31
|
"name": "constant.character.nu"
|
32
32
|
},
|
33
33
|
{
|
@@ -486,7 +486,7 @@
|
|
486
486
|
],
|
487
487
|
"repository": {
|
488
488
|
"escaped_char": {
|
489
|
-
"match": "\\\\([0-7]{3}|x
|
489
|
+
"match": "\\\\([0-7]{3}|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|.)",
|
490
490
|
"name": "constant.character.escape.nu"
|
491
491
|
},
|
492
492
|
"interpolated_nu": {
|
@@ -0,0 +1,711 @@
|
|
1
|
+
{
|
2
|
+
"scopeName": "source.pan",
|
3
|
+
"name": "Pan Template",
|
4
|
+
"fileTypes": [
|
5
|
+
"pan"
|
6
|
+
],
|
7
|
+
"firstLineMatch": "^s*(declaration|object|structure|unique)?s+templates",
|
8
|
+
"patterns": [
|
9
|
+
{
|
10
|
+
"include": "#comment"
|
11
|
+
},
|
12
|
+
{
|
13
|
+
"include": "#pipeline"
|
14
|
+
},
|
15
|
+
{
|
16
|
+
"include": "#list"
|
17
|
+
},
|
18
|
+
{
|
19
|
+
"include": "#compound-command"
|
20
|
+
},
|
21
|
+
{
|
22
|
+
"include": "#loop"
|
23
|
+
},
|
24
|
+
{
|
25
|
+
"include": "#function-definition"
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"include": "#string"
|
29
|
+
},
|
30
|
+
{
|
31
|
+
"include": "#variable"
|
32
|
+
},
|
33
|
+
{
|
34
|
+
"include": "#heredoc"
|
35
|
+
},
|
36
|
+
{
|
37
|
+
"include": "#redirection"
|
38
|
+
},
|
39
|
+
{
|
40
|
+
"include": "#pathname"
|
41
|
+
},
|
42
|
+
{
|
43
|
+
"include": "#keyword"
|
44
|
+
},
|
45
|
+
{
|
46
|
+
"include": "#support"
|
47
|
+
},
|
48
|
+
{
|
49
|
+
"include": "#annotation"
|
50
|
+
}
|
51
|
+
],
|
52
|
+
"repository": {
|
53
|
+
"case-clause": {
|
54
|
+
"patterns": [
|
55
|
+
{
|
56
|
+
"begin": "(?=\\S)",
|
57
|
+
"end": ";;",
|
58
|
+
"endCaptures": {
|
59
|
+
"0": {
|
60
|
+
"name": "punctuation.terminator.case-clause.pan"
|
61
|
+
}
|
62
|
+
},
|
63
|
+
"name": "meta.scope.case-clause.pan",
|
64
|
+
"patterns": [
|
65
|
+
{
|
66
|
+
"begin": "(\\(|(?=\\S))",
|
67
|
+
"captures": {
|
68
|
+
"0": {
|
69
|
+
"name": "punctuation.definition.case-pattern.pan"
|
70
|
+
}
|
71
|
+
},
|
72
|
+
"end": "\\)",
|
73
|
+
"name": "meta.scope.case-pattern.pan",
|
74
|
+
"patterns": [
|
75
|
+
{
|
76
|
+
"match": "\\|",
|
77
|
+
"name": "punctuation.separator.pipe-sign.pan"
|
78
|
+
},
|
79
|
+
{
|
80
|
+
"include": "#string"
|
81
|
+
},
|
82
|
+
{
|
83
|
+
"include": "#variable"
|
84
|
+
},
|
85
|
+
{
|
86
|
+
"include": "#pathname"
|
87
|
+
}
|
88
|
+
]
|
89
|
+
},
|
90
|
+
{
|
91
|
+
"begin": "(?<=\\))",
|
92
|
+
"end": "(?=;;)",
|
93
|
+
"name": "meta.scope.case-clause-body.pan",
|
94
|
+
"patterns": [
|
95
|
+
{
|
96
|
+
"include": "$self"
|
97
|
+
}
|
98
|
+
]
|
99
|
+
}
|
100
|
+
]
|
101
|
+
}
|
102
|
+
]
|
103
|
+
},
|
104
|
+
"comment": {
|
105
|
+
"begin": "(^\\s+)?(?<!\\S)(?=#)(?!#\\{)",
|
106
|
+
"beginCaptures": {
|
107
|
+
"1": {
|
108
|
+
"name": "punctuation.whitespace.comment.leading.pan"
|
109
|
+
}
|
110
|
+
},
|
111
|
+
"end": "(?!\\G)",
|
112
|
+
"patterns": [
|
113
|
+
{
|
114
|
+
"begin": "#!",
|
115
|
+
"beginCaptures": {
|
116
|
+
"0": {
|
117
|
+
"name": "punctuation.definition.comment.shebang.pan"
|
118
|
+
}
|
119
|
+
},
|
120
|
+
"end": "\\n",
|
121
|
+
"name": "comment.line.number-sign.shebang.pan"
|
122
|
+
},
|
123
|
+
{
|
124
|
+
"begin": "#",
|
125
|
+
"beginCaptures": {
|
126
|
+
"0": {
|
127
|
+
"name": "punctuation.definition.comment.pan"
|
128
|
+
}
|
129
|
+
},
|
130
|
+
"end": "\\n",
|
131
|
+
"name": "comment.line.number-sign.pan"
|
132
|
+
}
|
133
|
+
]
|
134
|
+
},
|
135
|
+
"compound-command": {
|
136
|
+
"patterns": [
|
137
|
+
{
|
138
|
+
"begin": "(\\[{1,2})",
|
139
|
+
"captures": {
|
140
|
+
"1": {
|
141
|
+
"name": "punctuation.definition.logical-expression.pan"
|
142
|
+
}
|
143
|
+
},
|
144
|
+
"end": "(\\]{1,2})",
|
145
|
+
"name": "meta.scope.logical-expression.pan",
|
146
|
+
"patterns": [
|
147
|
+
{
|
148
|
+
"include": "#logical-expression"
|
149
|
+
},
|
150
|
+
{
|
151
|
+
"include": "$self"
|
152
|
+
}
|
153
|
+
]
|
154
|
+
},
|
155
|
+
{
|
156
|
+
"begin": "(\\({2})",
|
157
|
+
"beginCaptures": {
|
158
|
+
"0": {
|
159
|
+
"name": "punctuation.definition.string.begin.pan"
|
160
|
+
}
|
161
|
+
},
|
162
|
+
"end": "(\\){2})",
|
163
|
+
"endCaptures": {
|
164
|
+
"0": {
|
165
|
+
"name": "punctuation.definition.string.end.pan"
|
166
|
+
}
|
167
|
+
},
|
168
|
+
"name": "string.other.math.pan",
|
169
|
+
"patterns": [
|
170
|
+
{
|
171
|
+
"include": "#math"
|
172
|
+
}
|
173
|
+
]
|
174
|
+
},
|
175
|
+
{
|
176
|
+
"begin": "(\\()",
|
177
|
+
"captures": {
|
178
|
+
"1": {
|
179
|
+
"name": "punctuation.definition.subpan.pan"
|
180
|
+
}
|
181
|
+
},
|
182
|
+
"end": "(\\))",
|
183
|
+
"name": "meta.scope.subpan.pan",
|
184
|
+
"patterns": [
|
185
|
+
{
|
186
|
+
"include": "$self"
|
187
|
+
}
|
188
|
+
]
|
189
|
+
},
|
190
|
+
{
|
191
|
+
"begin": "(?<=\\s|^)(\\{)(?=\\s|$)",
|
192
|
+
"captures": {
|
193
|
+
"1": {
|
194
|
+
"name": "punctuation.definition.group.pan"
|
195
|
+
}
|
196
|
+
},
|
197
|
+
"end": "(?<=^|;)\\s*(\\})",
|
198
|
+
"name": "meta.scope.group.pan",
|
199
|
+
"patterns": [
|
200
|
+
{
|
201
|
+
"include": "$self"
|
202
|
+
}
|
203
|
+
]
|
204
|
+
}
|
205
|
+
]
|
206
|
+
},
|
207
|
+
"function-definition": {
|
208
|
+
"patterns": [
|
209
|
+
{
|
210
|
+
"begin": "\\b(function)\\s+([^\\s\\\\]+)(?:\\s*(\\(\\)))?",
|
211
|
+
"beginCaptures": {
|
212
|
+
"1": {
|
213
|
+
"name": "storage.type.function.pan"
|
214
|
+
},
|
215
|
+
"2": {
|
216
|
+
"name": "entity.name.function.pan"
|
217
|
+
},
|
218
|
+
"3": {
|
219
|
+
"name": "punctuation.definition.arguments.pan"
|
220
|
+
}
|
221
|
+
},
|
222
|
+
"end": ";|&|$",
|
223
|
+
"endCaptures": {
|
224
|
+
"0": {
|
225
|
+
"name": "punctuation.definition.function.pan"
|
226
|
+
}
|
227
|
+
},
|
228
|
+
"name": "meta.function.pan",
|
229
|
+
"patterns": [
|
230
|
+
{
|
231
|
+
"include": "$self"
|
232
|
+
}
|
233
|
+
]
|
234
|
+
}
|
235
|
+
]
|
236
|
+
},
|
237
|
+
"heredoc": {
|
238
|
+
"patterns": [
|
239
|
+
{
|
240
|
+
"begin": "(<<)(\"|'|)\\\\?(\\w+)\\2",
|
241
|
+
"beginCaptures": {
|
242
|
+
"1": {
|
243
|
+
"name": "keyword.operator.heredoc.pan"
|
244
|
+
},
|
245
|
+
"3": {
|
246
|
+
"name": "keyword.control.heredoc-token.pan"
|
247
|
+
}
|
248
|
+
},
|
249
|
+
"captures": {
|
250
|
+
"0": {
|
251
|
+
"name": "punctuation.definition.string.pan"
|
252
|
+
}
|
253
|
+
},
|
254
|
+
"end": "^(\\3)\\b",
|
255
|
+
"endCaptures": {
|
256
|
+
"1": {
|
257
|
+
"name": "keyword.control.heredoc-token.pan"
|
258
|
+
}
|
259
|
+
},
|
260
|
+
"name": "string.unquoted.heredoc.pan"
|
261
|
+
}
|
262
|
+
]
|
263
|
+
},
|
264
|
+
"keyword": {
|
265
|
+
"patterns": [
|
266
|
+
{
|
267
|
+
"match": "(?<!-)\\b(if|else|for|foreach|while|return)\\b(?!-)",
|
268
|
+
"name": "keyword.control.pan"
|
269
|
+
},
|
270
|
+
{
|
271
|
+
"match": "\\b(include)\\b",
|
272
|
+
"name": "keyword.control.import.include.pan"
|
273
|
+
},
|
274
|
+
{
|
275
|
+
"match": "\\b(final)\\b",
|
276
|
+
"name": "storage.modifier.final.pan"
|
277
|
+
},
|
278
|
+
{
|
279
|
+
"match": "\\b(bind)\\b",
|
280
|
+
"name": "storage.modifier.bind.pan"
|
281
|
+
}
|
282
|
+
]
|
283
|
+
},
|
284
|
+
"support": {
|
285
|
+
"patterns": [
|
286
|
+
{
|
287
|
+
"match": "\\b(file_contents|file_exists|format|index|length|match|matches|replace|splice|split|substitute|substr|to_lowercase|to_uppercase)\\b",
|
288
|
+
"name": "support.function.pan.string"
|
289
|
+
},
|
290
|
+
{
|
291
|
+
"match": "\\b(debug|error|traceback|deprecated)\\b",
|
292
|
+
"name": "support.function.pan.debugging"
|
293
|
+
},
|
294
|
+
{
|
295
|
+
"match": "\\b(base64_decode|base64_encode|digest|escape|unescape)\\b",
|
296
|
+
"name": "support.function.pan.codec"
|
297
|
+
},
|
298
|
+
{
|
299
|
+
"match": "\\b(append|create|first|dict|key|length|list|merge|next|prepend|splice)\\b",
|
300
|
+
"name": "support.function.pan.resource"
|
301
|
+
},
|
302
|
+
{
|
303
|
+
"match": "\\b(is_boolean|is_defined|is_double|is_list|is_long|is_dict|is_null|is_number|is_property|is_resource|is_string)\\b",
|
304
|
+
"name": "support.function.pan.type.checking"
|
305
|
+
},
|
306
|
+
{
|
307
|
+
"match": "\\b(to_boolean|to_double|to_long|to_string|ip4_to_long|long_to_ip4)\\b",
|
308
|
+
"name": "support.function.pan.type.conversion"
|
309
|
+
},
|
310
|
+
{
|
311
|
+
"match": "\\b(clone|delete|exists|path_exists|if_exists|return|value)\\b",
|
312
|
+
"name": "support.function.pan.misc"
|
313
|
+
}
|
314
|
+
]
|
315
|
+
},
|
316
|
+
"list": {
|
317
|
+
"patterns": [
|
318
|
+
{
|
319
|
+
"match": ";|&&|&|\\|\\|",
|
320
|
+
"name": "keyword.operator.list.pan"
|
321
|
+
}
|
322
|
+
]
|
323
|
+
},
|
324
|
+
"logical-expression": {
|
325
|
+
"patterns": [
|
326
|
+
{
|
327
|
+
"match": "&&|\\|\\||==|!=|>|>=|<|<=",
|
328
|
+
"name": "keyword.operator.logical.pan"
|
329
|
+
},
|
330
|
+
{
|
331
|
+
"match": "&|\\|^",
|
332
|
+
"name": "keyword.operator.bitwise.pan"
|
333
|
+
}
|
334
|
+
]
|
335
|
+
},
|
336
|
+
"loop": {
|
337
|
+
"patterns": [
|
338
|
+
{
|
339
|
+
"begin": "\\b(for)\\s+(?=\\({2})",
|
340
|
+
"captures": {
|
341
|
+
"1": {
|
342
|
+
"name": "keyword.control.pan"
|
343
|
+
}
|
344
|
+
},
|
345
|
+
"end": "\\b(done)\\b",
|
346
|
+
"name": "meta.scope.for-loop.pan",
|
347
|
+
"patterns": [
|
348
|
+
{
|
349
|
+
"include": "$self"
|
350
|
+
}
|
351
|
+
]
|
352
|
+
},
|
353
|
+
{
|
354
|
+
"begin": "\\b(for)\\b\\s+(.+)\\s+\\b(in)\\b",
|
355
|
+
"beginCaptures": {
|
356
|
+
"1": {
|
357
|
+
"name": "keyword.control.pan"
|
358
|
+
},
|
359
|
+
"2": {
|
360
|
+
"name": "variable.other.loop.pan",
|
361
|
+
"patterns": [
|
362
|
+
{
|
363
|
+
"include": "#string"
|
364
|
+
}
|
365
|
+
]
|
366
|
+
},
|
367
|
+
"3": {
|
368
|
+
"name": "keyword.control.pan"
|
369
|
+
}
|
370
|
+
},
|
371
|
+
"end": "(?<![-/])\\bdone\\b(?![-/])",
|
372
|
+
"endCaptures": {
|
373
|
+
"0": {
|
374
|
+
"name": "keyword.control.pan"
|
375
|
+
}
|
376
|
+
},
|
377
|
+
"name": "meta.scope.for-in-loop.pan",
|
378
|
+
"patterns": [
|
379
|
+
{
|
380
|
+
"include": "$self"
|
381
|
+
}
|
382
|
+
]
|
383
|
+
},
|
384
|
+
{
|
385
|
+
"begin": "\\b(while|until)\\b",
|
386
|
+
"captures": {
|
387
|
+
"1": {
|
388
|
+
"name": "keyword.control.pan"
|
389
|
+
}
|
390
|
+
},
|
391
|
+
"end": "\\b(done)\\b",
|
392
|
+
"name": "meta.scope.while-loop.pan",
|
393
|
+
"patterns": [
|
394
|
+
{
|
395
|
+
"include": "$self"
|
396
|
+
}
|
397
|
+
]
|
398
|
+
},
|
399
|
+
{
|
400
|
+
"begin": "\\b(select)\\s+((?:[^\\s\\\\]|\\\\.)+)\\b",
|
401
|
+
"beginCaptures": {
|
402
|
+
"1": {
|
403
|
+
"name": "keyword.control.pan"
|
404
|
+
},
|
405
|
+
"2": {
|
406
|
+
"name": "variable.other.loop.pan"
|
407
|
+
}
|
408
|
+
},
|
409
|
+
"end": "\\b(done)\\b",
|
410
|
+
"endCaptures": {
|
411
|
+
"1": {
|
412
|
+
"name": "keyword.control.pan"
|
413
|
+
}
|
414
|
+
},
|
415
|
+
"name": "meta.scope.select-block.pan",
|
416
|
+
"patterns": [
|
417
|
+
{
|
418
|
+
"include": "$self"
|
419
|
+
}
|
420
|
+
]
|
421
|
+
},
|
422
|
+
{
|
423
|
+
"begin": "(?<!-)\\b(case)\\b(?!-)",
|
424
|
+
"captures": {
|
425
|
+
"1": {
|
426
|
+
"name": "keyword.control.pan"
|
427
|
+
}
|
428
|
+
},
|
429
|
+
"end": "\\b(esac)\\b",
|
430
|
+
"name": "meta.scope.case-block.pan",
|
431
|
+
"patterns": [
|
432
|
+
{
|
433
|
+
"begin": "\\b(?:in)\\b",
|
434
|
+
"beginCaptures": {
|
435
|
+
"1": {
|
436
|
+
"name": "keyword.control.pan"
|
437
|
+
}
|
438
|
+
},
|
439
|
+
"end": "(?=\\b(?:esac)\\b)",
|
440
|
+
"name": "meta.scope.case-body.pan",
|
441
|
+
"patterns": [
|
442
|
+
{
|
443
|
+
"include": "#comment"
|
444
|
+
},
|
445
|
+
{
|
446
|
+
"include": "#case-clause"
|
447
|
+
},
|
448
|
+
{
|
449
|
+
"include": "$self"
|
450
|
+
}
|
451
|
+
]
|
452
|
+
},
|
453
|
+
{
|
454
|
+
"include": "$self"
|
455
|
+
}
|
456
|
+
]
|
457
|
+
},
|
458
|
+
{
|
459
|
+
"begin": "(?<!-)\\b(if)\\b(?!-|\\s*=)",
|
460
|
+
"captures": {
|
461
|
+
"1": {
|
462
|
+
"name": "keyword.control.pan"
|
463
|
+
}
|
464
|
+
},
|
465
|
+
"end": "\\b(fi)\\b",
|
466
|
+
"name": "meta.scope.if-block.pan",
|
467
|
+
"patterns": [
|
468
|
+
{
|
469
|
+
"include": "$self"
|
470
|
+
}
|
471
|
+
]
|
472
|
+
}
|
473
|
+
]
|
474
|
+
},
|
475
|
+
"math": {
|
476
|
+
"patterns": [
|
477
|
+
{
|
478
|
+
"include": "#variable"
|
479
|
+
},
|
480
|
+
{
|
481
|
+
"match": "[-+*/%]",
|
482
|
+
"name": "keyword.operator.arithmetic.pan"
|
483
|
+
},
|
484
|
+
{
|
485
|
+
"match": "0[xX]\\h+",
|
486
|
+
"name": "constant.numeric.hex.pan"
|
487
|
+
},
|
488
|
+
{
|
489
|
+
"match": "0\\d+",
|
490
|
+
"name": "constant.numeric.octal.pan"
|
491
|
+
},
|
492
|
+
{
|
493
|
+
"match": "\\d{1,2}#[0-9a-zA-Z@_]+",
|
494
|
+
"name": "constant.numeric.other.pan"
|
495
|
+
},
|
496
|
+
{
|
497
|
+
"match": "\\d+",
|
498
|
+
"name": "constant.numeric.integer.pan"
|
499
|
+
}
|
500
|
+
]
|
501
|
+
},
|
502
|
+
"pathname": {
|
503
|
+
"patterns": [
|
504
|
+
{
|
505
|
+
"match": "(?<=\\s|:|=|^)~",
|
506
|
+
"name": "keyword.operator.tilde.pan"
|
507
|
+
},
|
508
|
+
{
|
509
|
+
"match": "\\*|\\?",
|
510
|
+
"name": "keyword.operator.glob.pan"
|
511
|
+
},
|
512
|
+
{
|
513
|
+
"begin": "([?*+@!])(\\()",
|
514
|
+
"beginCaptures": {
|
515
|
+
"1": {
|
516
|
+
"name": "keyword.operator.extglob.pan"
|
517
|
+
},
|
518
|
+
"2": {
|
519
|
+
"name": "punctuation.definition.extglob.pan"
|
520
|
+
}
|
521
|
+
},
|
522
|
+
"end": "(\\))",
|
523
|
+
"endCaptures": {
|
524
|
+
"1": {
|
525
|
+
"name": "punctuation.definition.extglob.pan"
|
526
|
+
}
|
527
|
+
},
|
528
|
+
"name": "meta.structure.extglob.pan",
|
529
|
+
"patterns": [
|
530
|
+
{
|
531
|
+
"include": "$self"
|
532
|
+
}
|
533
|
+
]
|
534
|
+
}
|
535
|
+
]
|
536
|
+
},
|
537
|
+
"pipeline": {
|
538
|
+
"patterns": [
|
539
|
+
{
|
540
|
+
"match": "\\b(time)\\b",
|
541
|
+
"name": "keyword.other.pan"
|
542
|
+
},
|
543
|
+
{
|
544
|
+
"match": "[|!]",
|
545
|
+
"name": "keyword.operator.pipe.pan"
|
546
|
+
}
|
547
|
+
]
|
548
|
+
},
|
549
|
+
"redirection": {
|
550
|
+
"patterns": [
|
551
|
+
{
|
552
|
+
"begin": "[><]\\(",
|
553
|
+
"beginCaptures": {
|
554
|
+
"0": {
|
555
|
+
"name": "punctuation.definition.string.begin.pan"
|
556
|
+
}
|
557
|
+
},
|
558
|
+
"end": "\\)",
|
559
|
+
"endCaptures": {
|
560
|
+
"0": {
|
561
|
+
"name": "punctuation.definition.string.end.pan"
|
562
|
+
}
|
563
|
+
},
|
564
|
+
"name": "string.interpolated.process-substitution.pan",
|
565
|
+
"patterns": [
|
566
|
+
{
|
567
|
+
"include": "$self"
|
568
|
+
}
|
569
|
+
]
|
570
|
+
},
|
571
|
+
{
|
572
|
+
"comment": "valid: &>word >&word >word [n]>&[n] [n]<word [n]>word [n]>>word [n]<&word (last one is duplicate)",
|
573
|
+
"match": "&>|\\d*>&\\d*|\\d*(>>|>|<)|\\d*<&|\\d*<>",
|
574
|
+
"name": "keyword.operator.redirect.pan"
|
575
|
+
}
|
576
|
+
]
|
577
|
+
},
|
578
|
+
"string": {
|
579
|
+
"patterns": [
|
580
|
+
{
|
581
|
+
"match": "\\\\.",
|
582
|
+
"name": "constant.character.escape.pan"
|
583
|
+
},
|
584
|
+
{
|
585
|
+
"begin": "'",
|
586
|
+
"beginCaptures": {
|
587
|
+
"0": {
|
588
|
+
"name": "punctuation.definition.string.begin.pan"
|
589
|
+
}
|
590
|
+
},
|
591
|
+
"end": "'",
|
592
|
+
"endCaptures": {
|
593
|
+
"0": {
|
594
|
+
"name": "punctuation.definition.string.end.pan"
|
595
|
+
}
|
596
|
+
},
|
597
|
+
"name": "string.quoted.single.pan"
|
598
|
+
},
|
599
|
+
{
|
600
|
+
"begin": "\\$?\"",
|
601
|
+
"beginCaptures": {
|
602
|
+
"0": {
|
603
|
+
"name": "punctuation.definition.string.begin.pan"
|
604
|
+
}
|
605
|
+
},
|
606
|
+
"end": "\"",
|
607
|
+
"endCaptures": {
|
608
|
+
"0": {
|
609
|
+
"name": "punctuation.definition.string.end.pan"
|
610
|
+
}
|
611
|
+
},
|
612
|
+
"name": "string.quoted.double.pan",
|
613
|
+
"patterns": [
|
614
|
+
{
|
615
|
+
"match": "\\\\[\\$`\"\\\\\\n]",
|
616
|
+
"name": "constant.character.escape.pan"
|
617
|
+
},
|
618
|
+
{
|
619
|
+
"include": "#variable"
|
620
|
+
},
|
621
|
+
{
|
622
|
+
"include": "#interpolation"
|
623
|
+
}
|
624
|
+
]
|
625
|
+
},
|
626
|
+
{
|
627
|
+
"begin": "\\$'",
|
628
|
+
"beginCaptures": {
|
629
|
+
"0": {
|
630
|
+
"name": "punctuation.definition.string.begin.pan"
|
631
|
+
}
|
632
|
+
},
|
633
|
+
"end": "'",
|
634
|
+
"endCaptures": {
|
635
|
+
"0": {
|
636
|
+
"name": "punctuation.definition.string.end.pan"
|
637
|
+
}
|
638
|
+
},
|
639
|
+
"name": "string.quoted.single.dollar.pan",
|
640
|
+
"patterns": [
|
641
|
+
{
|
642
|
+
"match": "\\\\(a|b|e|f|n|r|t|v|\\\\|')",
|
643
|
+
"name": "constant.character.escape.ansi-c.pan"
|
644
|
+
},
|
645
|
+
{
|
646
|
+
"match": "\\\\[0-9]{3}",
|
647
|
+
"name": "constant.character.escape.octal.pan"
|
648
|
+
},
|
649
|
+
{
|
650
|
+
"match": "\\\\x[0-9a-fA-F]{2}",
|
651
|
+
"name": "constant.character.escape.hex.pan"
|
652
|
+
},
|
653
|
+
{
|
654
|
+
"match": "\\\\c.",
|
655
|
+
"name": "constant.character.escape.control-char.pan"
|
656
|
+
}
|
657
|
+
]
|
658
|
+
}
|
659
|
+
]
|
660
|
+
},
|
661
|
+
"variable": {
|
662
|
+
"patterns": [
|
663
|
+
{
|
664
|
+
"captures": {
|
665
|
+
"1": {
|
666
|
+
"name": "storage.type.var.pan"
|
667
|
+
}
|
668
|
+
},
|
669
|
+
"match": "\\b(variable)\\s+(\\w+)\\b",
|
670
|
+
"name": "variable.other.pan"
|
671
|
+
},
|
672
|
+
{
|
673
|
+
"name": "storage.type.class.pan",
|
674
|
+
"match": "\\b(type)\\s+(\\w+)\\b",
|
675
|
+
"captures": {
|
676
|
+
"2": {
|
677
|
+
"name": "entity.name.type.pan"
|
678
|
+
}
|
679
|
+
}
|
680
|
+
}
|
681
|
+
]
|
682
|
+
},
|
683
|
+
"annotation": {
|
684
|
+
"patterns": [
|
685
|
+
{
|
686
|
+
"begin": "@(\\w+){",
|
687
|
+
"beginCaptures": {
|
688
|
+
"0": {
|
689
|
+
"name": "keyword.operator.comment.annotation.token.pan"
|
690
|
+
},
|
691
|
+
"1": {
|
692
|
+
"name": "keyword.operator.comment.annotation.name.pan"
|
693
|
+
}
|
694
|
+
},
|
695
|
+
"captures": {
|
696
|
+
"0": {
|
697
|
+
"name": "punctuation.definition.comment.pan"
|
698
|
+
}
|
699
|
+
},
|
700
|
+
"end": "(}$)",
|
701
|
+
"endCaptures": {
|
702
|
+
"1": {
|
703
|
+
"name": "keyword.control.annotation-token.pan"
|
704
|
+
}
|
705
|
+
},
|
706
|
+
"name": "comment.block.documentation.annotation.pan"
|
707
|
+
}
|
708
|
+
]
|
709
|
+
}
|
710
|
+
}
|
711
|
+
}
|