github-linguist 7.5.1 → 7.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +4 -4
  2. data/grammars/annotation.liquidhaskell.haskell.json +122 -24
  3. data/grammars/etc.json +7 -0
  4. data/grammars/hint.haskell.json +122 -24
  5. data/grammars/hint.message.haskell.json +122 -24
  6. data/grammars/hint.type.haskell.json +122 -24
  7. data/grammars/injections.etc.json +48 -10
  8. data/grammars/source.abnf.json +180 -353
  9. data/grammars/source.ballerina.json +205 -50
  10. data/grammars/source.bnf.json +191 -0
  11. data/grammars/source.cabal.json +1 -1
  12. data/grammars/source.ditroff.desc.json +1 -1
  13. data/grammars/source.ebnf.json +157 -147
  14. data/grammars/source.editorconfig.json +30 -5
  15. data/grammars/source.emacs.lisp.json +4 -4
  16. data/grammars/source.gremlin.json +200 -0
  17. data/grammars/source.haproxy-config.json +65 -13
  18. data/grammars/source.haskell.json +122 -24
  19. data/grammars/source.hql.json +1 -1
  20. data/grammars/source.hsig.json +122 -24
  21. data/grammars/source.hx.json +5 -5
  22. data/grammars/source.hxml.json +4 -4
  23. data/grammars/source.ideal.json +4 -4
  24. data/grammars/source.igor.json +325 -0
  25. data/grammars/source.jlex.json +322 -0
  26. data/grammars/source.julia.json +132 -1
  27. data/grammars/source.lean.json +103 -54
  28. data/grammars/source.lex.json +232 -0
  29. data/grammars/source.lex.regexp.json +269 -0
  30. data/grammars/source.logos.json +1 -1
  31. data/grammars/source.meson.json +1 -1
  32. data/grammars/source.mlir.json +389 -0
  33. data/grammars/source.nanorc.json +3 -0
  34. data/grammars/source.pic.json +19 -19
  35. data/grammars/source.plist.json +336 -0
  36. data/grammars/source.powershell.json +2 -2
  37. data/grammars/source.purescript.json +2 -2
  38. data/grammars/source.rascal.json +1 -0
  39. data/grammars/source.regexp.extended.json +544 -6
  40. data/grammars/source.regexp.json +408 -31
  41. data/grammars/source.renpy.json +3 -1
  42. data/grammars/source.scala.json +199 -97
  43. data/grammars/source.smpl.json +314 -0
  44. data/grammars/source.solidity.json +1 -1
  45. data/grammars/source.sourcepawn.json +654 -0
  46. data/grammars/source.sqf.json +5 -1
  47. data/grammars/source.swift.json +56 -11
  48. data/grammars/source.sy.json +800 -0
  49. data/grammars/source.ts.json +64 -47
  50. data/grammars/source.tsx.json +65 -48
  51. data/grammars/source.v.json +1184 -0
  52. data/grammars/source.viml.json +31 -31
  53. data/grammars/source.wollok.json +1 -1
  54. data/grammars/source.xojo.json +2 -2
  55. data/grammars/source.yacc.json +626 -0
  56. data/grammars/source.yara.json +1 -1
  57. data/grammars/source.yasnippet.json +15 -25
  58. data/grammars/source.zeek.json +4 -4
  59. data/grammars/source.zig.json +594 -195
  60. data/grammars/text.eml.basic.json +19 -6
  61. data/grammars/text.html.php.blade.json +3 -3
  62. data/grammars/text.plain.json +18 -0
  63. data/grammars/text.roff.json +926 -437
  64. data/grammars/text.runoff.json +3 -3
  65. data/grammars/text.tex.latex.haskell.json +122 -24
  66. data/grammars/text.texinfo.json +1525 -0
  67. data/grammars/text.xml.plist.json +664 -0
  68. data/grammars/text.xml.svg.json +556 -0
  69. data/grammars/version +1 -1
  70. data/lib/linguist.rb +3 -1
  71. data/lib/linguist/VERSION +1 -1
  72. data/lib/linguist/generated.rb +62 -17
  73. data/lib/linguist/heuristics.yml +13 -0
  74. data/lib/linguist/language.rb +1 -11
  75. data/lib/linguist/languages.json +1 -1
  76. data/lib/linguist/languages.yml +179 -19
  77. data/lib/linguist/samples.json +2778 -732
  78. data/lib/linguist/strategy/manpage.rb +42 -0
  79. metadata +22 -5
  80. data/grammars/source.bison.json +0 -55
  81. data/grammars/source.sp.json +0 -113
@@ -0,0 +1,322 @@
1
+ {
2
+ "name": "JLex",
3
+ "scopeName": "source.jlex",
4
+ "patterns": [
5
+ {
6
+ "include": "#main"
7
+ }
8
+ ],
9
+ "repository": {
10
+ "comments": {
11
+ "patterns": [
12
+ {
13
+ "name": "comment.line.double-slash.jlex",
14
+ "begin": "//",
15
+ "end": "$",
16
+ "beginCaptures": {
17
+ "0": {
18
+ "name": "punctuation.definition.comment.jlex"
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "comment.block.jlex",
24
+ "begin": "/\\*",
25
+ "end": "\\*/",
26
+ "beginCaptures": {
27
+ "0": {
28
+ "name": "punctuation.definition.begin.comment.jlex"
29
+ }
30
+ },
31
+ "endCaptures": {
32
+ "0": {
33
+ "name": "punctuation.definition.end.comment.jlex"
34
+ }
35
+ }
36
+ }
37
+ ]
38
+ },
39
+ "directive": {
40
+ "patterns": [
41
+ {
42
+ "match": "((%)(?:class|extends|implements|extends|cupsym))\\s+(\\S.*)",
43
+ "captures": {
44
+ "1": {
45
+ "name": "keyword.control.directive.jlex"
46
+ },
47
+ "2": {
48
+ "name": "punctuation.definition.directive.jlex"
49
+ },
50
+ "3": {
51
+ "name": "storage.type.class.var.jlex"
52
+ }
53
+ }
54
+ },
55
+ {
56
+ "match": "((%)include)\\s*(\\S.*)(?=$|//)",
57
+ "captures": {
58
+ "1": {
59
+ "name": "keyword.control.directive.jlex"
60
+ },
61
+ "2": {
62
+ "name": "punctuation.definition.directive.jlex"
63
+ },
64
+ "3": {
65
+ "patterns": [
66
+ {
67
+ "name": "storage.modifier.import.java",
68
+ "match": "[^\\s.]+"
69
+ },
70
+ {
71
+ "name": "punctuation.separator.java",
72
+ "match": "\\."
73
+ }
74
+ ]
75
+ }
76
+ }
77
+ },
78
+ {
79
+ "name": "meta.state-declarations.jlex",
80
+ "begin": "(%)state(?=\\s)(?!$)",
81
+ "end": "(?=$|/\\*)",
82
+ "patterns": [
83
+ {
84
+ "name": "variable.other.definition.jlex",
85
+ "match": "[A-Za-z_][A-Za-z_0-9]*"
86
+ },
87
+ {
88
+ "name": "punctuation.delimiter.comma.jlex",
89
+ "match": ","
90
+ }
91
+ ],
92
+ "beginCaptures": {
93
+ "0": {
94
+ "name": "keyword.control.directive.jlex"
95
+ },
96
+ "1": {
97
+ "name": "punctuation.definition.directive.jlex"
98
+ }
99
+ }
100
+ },
101
+ {
102
+ "name": "meta.code-block.directive.$3.jlex",
103
+ "begin": "^\\s*((%)(initthrow|init|eofthrow|eofval|eof))({)",
104
+ "end": "^\\s*((%)\\3)(})",
105
+ "patterns": [
106
+ {
107
+ "include": "source.java"
108
+ }
109
+ ],
110
+ "beginCaptures": {
111
+ "1": {
112
+ "name": "keyword.control.directive.jlex"
113
+ },
114
+ "2": {
115
+ "name": "punctuation.definition.directive.jlex"
116
+ },
117
+ "4": {
118
+ "name": "punctuation.definition.curly.bracket.begin.jlex"
119
+ }
120
+ },
121
+ "endCaptures": {
122
+ "1": {
123
+ "name": "keyword.control.directive.jlex"
124
+ },
125
+ "2": {
126
+ "name": "punctuation.definition.directive.jlex"
127
+ },
128
+ "3": {
129
+ "name": "punctuation.definition.curly.bracket.end.jlex"
130
+ }
131
+ }
132
+ },
133
+ {
134
+ "begin": "^\\s*((%)\\w+)(\\s+\\S.*)?",
135
+ "end": "(?=$)",
136
+ "beginCaptures": {
137
+ "1": {
138
+ "name": "keyword.control.directive.jlex"
139
+ },
140
+ "2": {
141
+ "name": "punctuation.definition.directive.jlex"
142
+ },
143
+ "3": {
144
+ "patterns": [
145
+ {
146
+ "include": "#comments"
147
+ },
148
+ {
149
+ "name": "constant.language.other.lex",
150
+ "match": "\\S+"
151
+ }
152
+ ]
153
+ }
154
+ }
155
+ }
156
+ ]
157
+ },
158
+ "directives": {
159
+ "name": "name.directives.jlex",
160
+ "begin": "^\\s*(%%)\\s*$\\s*",
161
+ "end": "^\\s*(%%)\\s*$\\s*",
162
+ "patterns": [
163
+ {
164
+ "include": "#passthrough"
165
+ },
166
+ {
167
+ "include": "#directive"
168
+ },
169
+ {
170
+ "include": "#comments"
171
+ },
172
+ {
173
+ "include": "#macro"
174
+ }
175
+ ],
176
+ "beginCaptures": {
177
+ "1": {
178
+ "name": "keyword.control.section.begin.jlex"
179
+ }
180
+ },
181
+ "endCaptures": {
182
+ "1": {
183
+ "name": "keyword.control.section.end.jlex"
184
+ }
185
+ }
186
+ },
187
+ "macro": {
188
+ "match": "^\\s*([^\\s=]+)\\s*(=)(\\s*\\S.*)$",
189
+ "captures": {
190
+ "1": {
191
+ "name": "entity.macro.name.jlex"
192
+ },
193
+ "2": {
194
+ "name": "keyword.operator.assignment.jlex"
195
+ },
196
+ "3": {
197
+ "name": "meta.macro.definition.jlex",
198
+ "patterns": [
199
+ {
200
+ "include": "source.lex.regexp"
201
+ }
202
+ ]
203
+ }
204
+ }
205
+ },
206
+ "main": {
207
+ "patterns": [
208
+ {
209
+ "include": "#comments"
210
+ },
211
+ {
212
+ "include": "#user-code"
213
+ },
214
+ {
215
+ "include": "#directives"
216
+ },
217
+ {
218
+ "include": "#rules"
219
+ }
220
+ ]
221
+ },
222
+ "passthrough": {
223
+ "name": "meta.code-chunk.jlex",
224
+ "begin": "^\\s*%{",
225
+ "end": "^\\s*%}",
226
+ "patterns": [
227
+ {
228
+ "include": "source.java"
229
+ }
230
+ ],
231
+ "beginCaptures": {
232
+ "0": {
233
+ "name": "punctuation.section.embedded.begin.jlex"
234
+ }
235
+ },
236
+ "endCaptures": {
237
+ "0": {
238
+ "name": "punctuation.section.embedded.end.jlex"
239
+ }
240
+ }
241
+ },
242
+ "rules": {
243
+ "patterns": [
244
+ {
245
+ "name": "meta.rule.jlex",
246
+ "begin": "^\\s*(\"[^\"]+\")\\s+({)",
247
+ "end": "}",
248
+ "patterns": [
249
+ {
250
+ "include": "source.java"
251
+ }
252
+ ],
253
+ "beginCaptures": {
254
+ "1": {
255
+ "patterns": [
256
+ {
257
+ "include": "source.lex.regexp#string"
258
+ }
259
+ ]
260
+ },
261
+ "2": {
262
+ "name": "punctuation.definition.curly.bracket.begin.jlex"
263
+ }
264
+ },
265
+ "endCaptures": {
266
+ "0": {
267
+ "name": "punctuation.definition.curly.bracket.begin.jlex"
268
+ }
269
+ }
270
+ },
271
+ {
272
+ "name": "meta.rule.jlex",
273
+ "begin": "^([^{]*[^\\s{][^{]*)({\\w+}\\s*)?({)",
274
+ "end": "}",
275
+ "patterns": [
276
+ {
277
+ "include": "source.java"
278
+ }
279
+ ],
280
+ "beginCaptures": {
281
+ "1": {
282
+ "patterns": [
283
+ {
284
+ "include": "source.lex.regexp"
285
+ }
286
+ ]
287
+ },
288
+ "2": {
289
+ "patterns": [
290
+ {
291
+ "include": "source.lex.regexp"
292
+ }
293
+ ]
294
+ },
295
+ "3": {
296
+ "name": "punctuation.definition.curly.bracket.begin.jlex"
297
+ }
298
+ },
299
+ "endCaptures": {
300
+ "0": {
301
+ "name": "punctuation.definition.curly.bracket.begin.jlex"
302
+ }
303
+ }
304
+ }
305
+ ]
306
+ },
307
+ "user-code": {
308
+ "patterns": [
309
+ {
310
+ "name": "meta.user-code.jlex",
311
+ "begin": "\\G",
312
+ "end": "^(?=\\s*%%)",
313
+ "patterns": [
314
+ {
315
+ "include": "source.java"
316
+ }
317
+ ]
318
+ }
319
+ ]
320
+ }
321
+ }
322
+ }
@@ -562,6 +562,114 @@
562
562
  }
563
563
  }
564
564
  },
565
+ {
566
+ "name": "embed.R.julia",
567
+ "contentName": "source.r",
568
+ "begin": "(R)(\"\"\")",
569
+ "end": "\"\"\"",
570
+ "patterns": [
571
+ {
572
+ "include": "source.r"
573
+ },
574
+ {
575
+ "include": "#string_dollar_sign_interpolate"
576
+ }
577
+ ],
578
+ "beginCaptures": {
579
+ "1": {
580
+ "name": "support.function.macro.julia"
581
+ },
582
+ "2": {
583
+ "name": "punctuation.definition.string.begin.julia"
584
+ }
585
+ },
586
+ "endCaptures": {
587
+ "0": {
588
+ "name": "punctuation.definition.string.end.julia"
589
+ }
590
+ }
591
+ },
592
+ {
593
+ "name": "embed.R.julia",
594
+ "contentName": "source.r",
595
+ "begin": "(R)(\")",
596
+ "end": "\"",
597
+ "patterns": [
598
+ {
599
+ "include": "source.r"
600
+ },
601
+ {
602
+ "include": "#string_dollar_sign_interpolate"
603
+ }
604
+ ],
605
+ "beginCaptures": {
606
+ "1": {
607
+ "name": "support.function.macro.julia"
608
+ },
609
+ "2": {
610
+ "name": "punctuation.definition.string.begin.julia"
611
+ }
612
+ },
613
+ "endCaptures": {
614
+ "0": {
615
+ "name": "punctuation.definition.string.end.julia"
616
+ }
617
+ }
618
+ },
619
+ {
620
+ "name": "embed.markdown.julia",
621
+ "contentName": "source.gfm",
622
+ "begin": "(md)(\"\"\")",
623
+ "end": "\"\"\"",
624
+ "patterns": [
625
+ {
626
+ "include": "source.gfm"
627
+ },
628
+ {
629
+ "include": "#string_dollar_sign_interpolate"
630
+ }
631
+ ],
632
+ "beginCaptures": {
633
+ "1": {
634
+ "name": "support.function.macro.julia"
635
+ },
636
+ "2": {
637
+ "name": "punctuation.definition.string.begin.julia"
638
+ }
639
+ },
640
+ "endCaptures": {
641
+ "0": {
642
+ "name": "punctuation.definition.string.end.julia"
643
+ }
644
+ }
645
+ },
646
+ {
647
+ "name": "embed.markdown.julia",
648
+ "contentName": "source.gfm",
649
+ "begin": "(md)(\")",
650
+ "end": "\"",
651
+ "patterns": [
652
+ {
653
+ "include": "source.gfm"
654
+ },
655
+ {
656
+ "include": "#string_dollar_sign_interpolate"
657
+ }
658
+ ],
659
+ "beginCaptures": {
660
+ "1": {
661
+ "name": "support.function.macro.julia"
662
+ },
663
+ "2": {
664
+ "name": "punctuation.definition.string.begin.julia"
665
+ }
666
+ },
667
+ "endCaptures": {
668
+ "0": {
669
+ "name": "punctuation.definition.string.end.julia"
670
+ }
671
+ }
672
+ },
565
673
  {
566
674
  "name": "string.docstring.julia",
567
675
  "begin": "^\\s?(doc|raw)?(\"\"\")\\s?$",
@@ -654,6 +762,29 @@
654
762
  }
655
763
  }
656
764
  },
765
+ {
766
+ "name": "string.regexp.julia",
767
+ "begin": "r\"\"\"",
768
+ "end": "(\"\"\")([imsx]{0,4})?",
769
+ "patterns": [
770
+ {
771
+ "include": "#string_escaped_char"
772
+ }
773
+ ],
774
+ "beginCaptures": {
775
+ "0": {
776
+ "name": "punctuation.definition.string.regexp.begin.julia"
777
+ }
778
+ },
779
+ "endCaptures": {
780
+ "1": {
781
+ "name": "punctuation.definition.string.regexp.end.julia"
782
+ },
783
+ "2": {
784
+ "name": "keyword.other.option-toggle.regexp.julia"
785
+ }
786
+ }
787
+ },
657
788
  {
658
789
  "name": "string.regexp.julia",
659
790
  "begin": "r\"",
@@ -705,7 +836,7 @@
705
836
  },
706
837
  {
707
838
  "name": "string.quoted.other.julia",
708
- "begin": "(?\u003c!\")([[:alpha:]_∇][[:word:]⁺-ₜ!′∇]*)\"(?!\")",
839
+ "begin": "(?\u003c!\")([[:alpha:]_∇][[:word:]⁺-ₜ!′∇]*)\"",
709
840
  "end": "(?\u003c![^\\\\]\\\\)(\")([[:alpha:]_∇][[:word:]⁺-ₜ!′∇]*)?",
710
841
  "patterns": [
711
842
  {