github-linguist 4.8.9 → 4.8.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/bin/git-linguist +2 -2
  3. data/grammars/source.ats.json +58 -128
  4. data/grammars/source.autoit.json +158 -153
  5. data/grammars/source.awk.json +333 -383
  6. data/grammars/source.batchfile.json +194 -0
  7. data/grammars/source.c.platform.json +359 -22
  8. data/grammars/source.changelogs.rpm-spec.json +99 -0
  9. data/grammars/source.clojure.json +9 -3
  10. data/grammars/source.dockerfile.json +67 -78
  11. data/grammars/source.elm.json +20 -379
  12. data/grammars/source.emacs.lisp.json +656 -0
  13. data/grammars/source.gdscript.json +233 -228
  14. data/grammars/source.graphql.json +75 -10
  15. data/grammars/source.js.json +2 -2
  16. data/grammars/source.js.jsx.json +247 -839
  17. data/grammars/source.js.regexp.json +1 -1
  18. data/grammars/source.nginx.json +882 -768
  19. data/grammars/source.nsis.json +151 -143
  20. data/grammars/source.objc.json +3 -0
  21. data/grammars/source.objc.platform.json +174 -104
  22. data/grammars/source.puppet.json +429 -396
  23. data/grammars/source.pyjade.json +11 -0
  24. data/grammars/source.regexp.babel.json +1 -1
  25. data/grammars/source.rpm-spec.json +770 -0
  26. data/grammars/source.systemverilog.json +1110 -961
  27. data/grammars/source.ts.json +57 -57
  28. data/grammars/source.tsx.json +57 -57
  29. data/grammars/text.dart-analysis-output.json +67 -152
  30. data/grammars/text.error-list.json +54 -0
  31. data/grammars/text.find-refs.json +927 -0
  32. data/grammars/text.html.basic.json +1 -1
  33. data/grammars/text.html.mediawiki.elm-build-output.json +108 -0
  34. data/grammars/text.html.mediawiki.elm-documentation.json +22 -0
  35. data/grammars/text.html.vue.json +35 -0
  36. data/grammars/text.jade.json +34 -12
  37. data/grammars/text.roff.json +1 -1
  38. data/lib/linguist/heuristics.rb +16 -4
  39. data/lib/linguist/languages.json +1 -1
  40. data/lib/linguist/languages.yml +25 -5
  41. data/lib/linguist/samples.json +1367 -163
  42. data/lib/linguist/version.rb +1 -1
  43. metadata +10 -3
  44. data/grammars/source.dosbatch.json +0 -70
@@ -1,249 +1,254 @@
1
1
  {
2
- "fileTypes": [
2
+ "name": "GDScript (Godot Engine)",
3
+ "file_extensions": [
3
4
  "gd"
4
5
  ],
5
- "name": "GDScript (Godot Engine)",
6
- "patterns": [
7
- {
8
- "captures": {
9
- "1": {
10
- "name": "punctuation.definition.comment.number-sign.gdscript"
6
+ "scope": "source.gdscript",
7
+ "contexts": {
8
+ "main": [
9
+ {
10
+ "match": "(#).*$\\n?",
11
+ "scope": "comment.line.number-sign.gdscript",
12
+ "captures": {
13
+ "1": "punctuation.definition.comment.number-sign.gdscript"
11
14
  }
12
15
  },
13
- "match": "(#).*$\\n?",
14
- "name": "comment.line.number-sign.gdscript"
15
- },
16
- {
17
- "begin": "^(\"\"\")",
18
- "beginCaptures": {
19
- "1": {
20
- "name": "punctuation.definition.comment.triple-quote.gdscript"
21
- }
16
+ {
17
+ "match": "^(\"\"\")",
18
+ "captures": {
19
+ "1": "punctuation.definition.comment.triple-quote.gdscript"
20
+ },
21
+ "push": [
22
+ {
23
+ "meta_scope": "comment.block.triple-quote"
24
+ },
25
+ {
26
+ "match": "(\"\"\")",
27
+ "captures": {
28
+ "1": "punctuation.definition.comment.triple-quote.gdscript"
29
+ },
30
+ "pop": true
31
+ }
32
+ ]
22
33
  },
23
- "end": "(\"\"\")",
24
- "endCaptures": {
25
- "1": {
26
- "name": "punctuation.definition.comment.triple-quote.gdscript"
27
- }
34
+ {
35
+ "match": "\"",
36
+ "push": [
37
+ {
38
+ "meta_scope": "string.quoted.double.gdscript"
39
+ },
40
+ {
41
+ "match": "(?<!\\\\)\"",
42
+ "pop": true
43
+ }
44
+ ]
28
45
  },
29
- "name": "comment.block.triple-quote"
30
- },
31
- {
32
- "begin": "\"",
33
- "end": "(?<!\\\\)\"",
34
- "name": "string.quoted.double.gdscript"
35
- },
36
- {
37
- "begin": "'",
38
- "end": "(?<!\\\\)'",
39
- "name": "string.quoted.single.gdscript"
40
- },
41
- {
42
- "begin": "\"\"\"",
43
- "end": "(?<!\\\\)\"\"\"",
44
- "name": "string.quoted.triple.gdscript"
45
- },
46
- {
47
- "begin": "@\"",
48
- "end": "(?<!\\\\)\"",
49
- "name": "string.quoted.double.node-path.gdscript"
50
- },
51
- {
52
- "match": "\\b(?i:0x\\h*)\\b",
53
- "name": "constant.numeric.integer.hexadecimal.gdscript"
54
- },
55
- {
56
- "match": "\\b(?i:(\\d+\\.\\d*(e[\\-\\+]?\\d+)?))\\b",
57
- "name": "constant.numeric.float.gdscript"
58
- },
59
- {
60
- "match": "\\b(?i:(\\.\\d+(e[\\-\\+]?\\d+)?))\\b",
61
- "name": "constant.numeric.float.gdscript"
62
- },
63
- {
64
- "match": "\\b(?i:(\\d+e[\\-\\+]?\\d+))\\b",
65
- "name": "constant.numeric.float.gdscript"
66
- },
67
- {
68
- "match": "\\b\\d+\\b",
69
- "name": "constant.numeric.integer.gdscript"
70
- },
71
- {
72
- "match": "\\b(?i:elif|else|for|if|while|break|continue|pass|return)\\b",
73
- "name": "keyword.control.flow.gdscript"
74
- },
75
- {
76
- "match": "\\b(?i:&&|and|in|is|!|not|\\|\\||or)\\b",
77
- "name": "keyword.operator.logical.gdscript"
78
- },
79
- {
80
- "match": "<=|>=|==|<|>|!=",
81
- "name": "keyword.operator.comparison.gdscript"
82
- },
83
- {
84
- "match": "\\+=|-=|\\*=|/=|%=|&=|\\|=|\\*|/|%|\\+|-|<<|>>|&|\\||\\^|~",
85
- "name": "keyword.operator.arithmetic.gdscript"
86
- },
87
- {
88
- "match": "=",
89
- "name": "keyword.operator.assignment.gdscript"
90
- },
91
- {
92
- "match": "\\b(bool|int|float|String|funcref)\\b",
93
- "name": "support.type.basic.gdscript"
94
- },
95
- {
96
- "match": "\\b(Vector[23]|Rect2|Matrix32?|Plane|Quat|AABB|Transform)\\b",
97
- "name": "support.type.vector.gdscript"
98
- },
99
- {
100
- "match": "\\b(Color|Image|NodePath|RID|Object|InputEvent)\\b",
101
- "name": "support.type.engine.gdscript"
102
- },
103
- {
104
- "match": "\\b(Array|Dictionary|ByteArray|IntArray|FloatArray|StringArray|Vector[23]Array|ColorArray)\\b",
105
- "name": "support.type.container.gdscript"
106
- },
107
- {
108
- "captures": {
109
- "1": {
110
- "name": "storage.type.class.gdscript"
111
- },
112
- "2": {
113
- "name": "entity.name.type.class.gdscript"
114
- }
46
+ {
47
+ "match": "'",
48
+ "push": [
49
+ {
50
+ "meta_scope": "string.quoted.single.gdscript"
51
+ },
52
+ {
53
+ "match": "(?<!\\\\)'",
54
+ "pop": true
55
+ }
56
+ ]
115
57
  },
116
- "match": "^\\s*(?i:(class))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*:"
117
- },
118
- {
119
- "begin": "^\\s*(?i:(?:(static)\\s+)?(func))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*\\(",
120
- "beginCaptures": {
121
- "1": {
122
- "name": "storage.modifier.static-function.gdscript"
123
- },
124
- "2": {
125
- "name": "storage.type.function.gdscript"
126
- },
127
- "3": {
128
- "name": "entity.name.function.gdscript"
129
- }
58
+ {
59
+ "match": "\"\"\"",
60
+ "push": [
61
+ {
62
+ "meta_scope": "string.quoted.triple.gdscript"
63
+ },
64
+ {
65
+ "match": "(?<!\\\\)\"\"\"",
66
+ "pop": true
67
+ }
68
+ ]
130
69
  },
131
- "end": "\\)\\s*:",
132
- "patterns": [
133
- {
134
- "match": "[a-zA-Z_][a-zA-Z_0-9]*",
135
- "name": "variable.parameter.gdscript"
136
- }
137
- ]
138
- },
139
- {
140
- "begin": "^\\s*(?i:(signal))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*\\(",
141
- "beginCaptures": {
142
- "1": {
143
- "name": "storage.type.signal.gdscript"
144
- },
145
- "2": {
146
- "name": "entity.name.function.siglan.gdscript"
147
- }
70
+ {
71
+ "match": "@\"",
72
+ "push": [
73
+ {
74
+ "meta_scope": "string.quoted.double.node-path.gdscript"
75
+ },
76
+ {
77
+ "match": "(?<!\\\\)\"",
78
+ "pop": true
79
+ }
80
+ ]
148
81
  },
149
- "end": "\\)\\s*:",
150
- "patterns": [
151
- {
152
- "match": "[a-zA-Z_][a-zA-Z_0-9]*",
153
- "name": "variable.parameter.gdscript"
154
- }
155
- ]
156
- },
157
- {
158
- "captures": {
159
- "1": {
160
- "name": "keyword.other.onready.gdscript"
161
- },
162
- "2": {
163
- "name": "storage.type.var.gdscript"
164
- },
165
- "3": {
166
- "name": "variable.other.gdscript"
167
- }
82
+ {
83
+ "match": "\\b(?i:0x\\h*)\\b",
84
+ "scope": "constant.numeric.integer.hexadecimal.gdscript"
168
85
  },
169
- "match": "(?i:\\b(?:(onready)\\s+)?(var))\\s+([a-zA-Z_][a-zA-Z_0-9]*)"
170
- },
171
- {
172
- "captures": {
173
- "1": {
174
- "name": "storage.type.const.gdscript"
175
- },
176
- "2": {
177
- "name": "variable.other.gdscript"
86
+ {
87
+ "match": "\\b(?i:(\\d+\\.\\d*(e[\\-\\+]?\\d+)?))\\b",
88
+ "scope": "constant.numeric.float.gdscript"
89
+ },
90
+ {
91
+ "match": "\\b(?i:(\\.\\d+(e[\\-\\+]?\\d+)?))\\b",
92
+ "scope": "constant.numeric.float.gdscript"
93
+ },
94
+ {
95
+ "match": "\\b(?i:(\\d+e[\\-\\+]?\\d+))\\b",
96
+ "scope": "constant.numeric.float.gdscript"
97
+ },
98
+ {
99
+ "match": "\\b\\d+\\b",
100
+ "scope": "constant.numeric.integer.gdscript"
101
+ },
102
+ {
103
+ "match": "\\b(?i:elif|else|for|if|while|break|continue|pass|return)\\b",
104
+ "scope": "keyword.control.flow.gdscript"
105
+ },
106
+ {
107
+ "match": "\\b(?i:&&|and|in|is|!|not|\\|\\||or)\\b",
108
+ "scope": "keyword.operator.logical.gdscript"
109
+ },
110
+ {
111
+ "match": "<=|>=|==|<|>|!=",
112
+ "scope": "keyword.operator.comparison.gdscript"
113
+ },
114
+ {
115
+ "match": "\\+=|-=|\\*=|/=|%=|&=|\\|=|\\*|/|%|\\+|-|<<|>>|&|\\||\\^|~",
116
+ "scope": "keyword.operator.arithmetic.gdscript"
117
+ },
118
+ {
119
+ "match": "=",
120
+ "scope": "keyword.operator.assignment.gdscript"
121
+ },
122
+ {
123
+ "match": "\\b(bool|int|float|String|funcref)\\b",
124
+ "scope": "support.type.basic.gdscript"
125
+ },
126
+ {
127
+ "match": "\\b(Vector[23]|Rect2|Matrix32?|Plane|Quat|AABB|Transform)\\b",
128
+ "scope": "support.type.vector.gdscript"
129
+ },
130
+ {
131
+ "match": "\\b(Color|Image|NodePath|RID|Object|InputEvent)\\b",
132
+ "scope": "support.type.engine.gdscript"
133
+ },
134
+ {
135
+ "match": "\\b(Array|Dictionary|ByteArray|IntArray|FloatArray|StringArray|Vector[23]Array|ColorArray)\\b",
136
+ "scope": "support.type.container.gdscript"
137
+ },
138
+ {
139
+ "match": "^\\s*(?i:(class))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*:",
140
+ "captures": {
141
+ "1": "storage.type.class.gdscript",
142
+ "2": "entity.name.type.class.gdscript"
178
143
  }
179
144
  },
180
- "match": "\\b(?i:(const))\\s+([a-zA-Z_][a-zA-Z_0-9]*)"
181
- },
182
- {
183
- "match": "\\b(?i:extends|assert|breakpoint)\\b",
184
- "name": "keyword.other.gdscript"
185
- },
186
- {
187
- "match": "(?<=extends)\\s+[a-zA-Z_][a-zA-Z_0-9]*(\\.([a-zA-Z_][a-zA-Z_0-9]*))?",
188
- "name": "entity.other.inherited-class.gdscript"
189
- },
190
- {
191
- "match": "\\b(?i:true|false|null)\\b",
192
- "name": "constant.language.gdscript"
193
- },
194
- {
195
- "match": "\\b(?i:export|tool)\\b",
196
- "name": "storage.modifier.static.gdscript"
197
- },
198
- {
199
- "captures": {
200
- "1": {
201
- "name": "keyword.operator.setget.gdscript"
202
- },
203
- "2": {
204
- "name": "entity.name.function.gdscript"
145
+ {
146
+ "match": "^\\s*(?i:(?:(static)\\s+)?(func))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*\\(",
147
+ "captures": {
148
+ "1": "storage.modifier.static-function.gdscript",
149
+ "2": "storage.type.function.gdscript",
150
+ "3": "entity.name.function.gdscript"
205
151
  },
206
- "3": {
207
- "name": "entity.name.function.gdscript"
152
+ "push": [
153
+ {
154
+ "match": "\\)\\s*:",
155
+ "pop": true
156
+ },
157
+ {
158
+ "match": "[a-zA-Z_][a-zA-Z_0-9]*",
159
+ "scope": "variable.parameter.gdscript"
160
+ }
161
+ ]
162
+ },
163
+ {
164
+ "match": "^\\s*(?i:(signal))\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*\\(",
165
+ "captures": {
166
+ "1": "storage.type.signal.gdscript",
167
+ "2": "entity.name.function.siglan.gdscript"
208
168
  },
209
- "4": {
210
- "name": "entity.name.function.gdscript"
169
+ "push": [
170
+ {
171
+ "match": "\\)\\s*:",
172
+ "pop": true
173
+ },
174
+ {
175
+ "match": "[a-zA-Z_][a-zA-Z_0-9]*",
176
+ "scope": "variable.parameter.gdscript"
177
+ }
178
+ ]
179
+ },
180
+ {
181
+ "match": "(?i:\\b(?:(onready)\\s+)?(var))\\s+([a-zA-Z_][a-zA-Z_0-9]*)",
182
+ "captures": {
183
+ "1": "keyword.other.onready.gdscript",
184
+ "2": "storage.type.var.gdscript",
185
+ "3": "variable.other.gdscript"
211
186
  }
212
187
  },
213
- "match": "\\b((?i:setget))\\b\\s+(?:,?([a-zA-Z_][a-zA-Z_0-9]*)|([a-zA-Z_][a-zA-Z_0-9]*)\\s*,\\s*([a-zA-Z_][a-zA-Z_0-9]*))"
214
- },
215
- {
216
- "match": "\\b(?i:yield)\\b",
217
- "name": "keyword.control.flow.yield.gdscript"
218
- },
219
- {
220
- "match": "\\b(?i:var|const|onready|class|func|signal)\\b",
221
- "name": "invalid.illegal"
222
- },
223
- {
224
- "match": "([A-Z][a-zA-Z_0-9]*)",
225
- "name": "entity.name.type.class-type.gdscript"
226
- },
227
- {
228
- "match": "([a-z_][a-zA-Z_0-9]*)",
229
- "name": "entity.name.type.variant.gdscript"
230
- },
231
- {
232
- "begin": "([a-z][a-zA-Z_0-9]*)\\s*\\(",
233
- "beginCaptures": {
234
- "1": {
235
- "name": "entity.name.function.reference.gdscript"
188
+ {
189
+ "match": "\\b(?i:(const))\\s+([a-zA-Z_][a-zA-Z_0-9]*)",
190
+ "captures": {
191
+ "1": "storage.type.const.gdscript",
192
+ "2": "variable.other.gdscript"
236
193
  }
237
194
  },
238
- "end": "\\)",
239
- "patterns": [
240
- {
241
- "match": "([a-zA-Z_][a-zA-Z_0-9]*)",
242
- "name": "variable.parameter.gdscript"
195
+ {
196
+ "match": "\\b(?i:extends|assert|breakpoint)\\b",
197
+ "scope": "keyword.other.gdscript"
198
+ },
199
+ {
200
+ "match": "(?<=extends)\\s+[a-zA-Z_][a-zA-Z_0-9]*(\\.([a-zA-Z_][a-zA-Z_0-9]*))?",
201
+ "scope": "entity.other.inherited-class.gdscript"
202
+ },
203
+ {
204
+ "match": "\\b(?i:true|false|null)\\b",
205
+ "scope": "constant.language.gdscript"
206
+ },
207
+ {
208
+ "match": "\\b(?i:export|tool)\\b",
209
+ "scope": "storage.modifier.static.gdscript"
210
+ },
211
+ {
212
+ "match": "\\b((?i:setget))\\b\\s+(?:,?([a-zA-Z_][a-zA-Z_0-9]*)|([a-zA-Z_][a-zA-Z_0-9]*)\\s*,\\s*([a-zA-Z_][a-zA-Z_0-9]*))",
213
+ "captures": {
214
+ "1": "keyword.operator.setget.gdscript",
215
+ "2": "entity.name.function.gdscript",
216
+ "3": "entity.name.function.gdscript",
217
+ "4": "entity.name.function.gdscript"
243
218
  }
244
- ]
245
- }
246
- ],
247
- "scopeName": "source.gdscript",
248
- "uuid": "e08b7d98-5d50-4aa9-8935-7c759a4a8fdd"
219
+ },
220
+ {
221
+ "match": "\\b(?i:yield)\\b",
222
+ "scope": "keyword.control.flow.yield.gdscript"
223
+ },
224
+ {
225
+ "match": "\\b(?i:var|const|onready|class|func|signal)\\b",
226
+ "scope": "invalid.illegal"
227
+ },
228
+ {
229
+ "match": "([A-Z][a-zA-Z_0-9]*)",
230
+ "scope": "entity.name.type.class-type.gdscript"
231
+ },
232
+ {
233
+ "match": "([a-z_][a-zA-Z_0-9]*)",
234
+ "scope": "entity.name.type.variant.gdscript"
235
+ },
236
+ {
237
+ "match": "([a-z][a-zA-Z_0-9]*)\\s*\\(",
238
+ "captures": {
239
+ "1": "entity.name.function.reference.gdscript"
240
+ },
241
+ "push": [
242
+ {
243
+ "match": "\\)",
244
+ "pop": true
245
+ },
246
+ {
247
+ "match": "([a-zA-Z_][a-zA-Z_0-9]*)",
248
+ "scope": "variable.parameter.gdscript"
249
+ }
250
+ ]
251
+ }
252
+ ]
253
+ }
249
254
  }