github-linguist 4.8.6 → 4.8.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -866,6 +866,22 @@
866
866
  "name": "keyword.function.$1.wavefront.mtl"
867
867
  }
868
868
  }
869
+ },
870
+ {
871
+ "name": "meta.texture-map.other.$2.wavefront.mtl",
872
+ "begin": "^\\s*(map_([-\\w]+))(?=\\s|$|#)",
873
+ "end": "(?=$|#)",
874
+ "contentName": "meta.options.wavefront.mtl",
875
+ "patterns": [
876
+ {
877
+ "include": "#texture-options"
878
+ }
879
+ ],
880
+ "beginCaptures": {
881
+ "1": {
882
+ "name": "keyword.function.$1.wavefront.mtl"
883
+ }
884
+ }
869
885
  }
870
886
  ]
871
887
  },
@@ -430,7 +430,7 @@
430
430
  ]
431
431
  },
432
432
  "block_helper": {
433
- "begin": "(\\{\\{~?\\#)([-a-zA-Z0-9_\\./]+)\\s?(@?[-a-zA-Z0-9_\\./]+=?)*\\s?(@?[-a-zA-Z0-9_\\./]+)*\\s?(@?[-a-zA-Z0-9_\\./]+)*",
433
+ "begin": "(\\{\\{~?\\#)([-a-zA-Z0-9_\\./]+)\\s?(@?[-a-zA-Z0-9_\\./]+)*\\s?(@?[-a-zA-Z0-9_\\./]+)*\\s?(@?[-a-zA-Z0-9_\\./]+)*",
434
434
  "end": "(~?\\}\\})",
435
435
  "name": "meta.function.block.start.handlebars",
436
436
  "endCaptures": {
@@ -549,24 +549,41 @@
549
549
  }
550
550
  ]
551
551
  },
552
- "handlebars_attribute": {
553
- "begin": "\\b([\\.a-zA-Z0-9_-]+)\\b\\s*(=)?",
552
+ "handlebars_attribute_name": {
553
+ "begin": "\\b([\\.a-zA-Z0-9_-]+)\\b=",
554
554
  "captures": {
555
555
  "1": {
556
556
  "name": "variable.parameter.handlebars"
557
- },
558
- "2": {
559
- "name": "variable.parameter.handlebars"
560
557
  }
561
558
  },
562
559
  "end": "(?='|\"|)",
563
- "name": "entity.other.attribute-name.handlebars",
560
+ "name": "entity.other.attribute-name.handlebars"
561
+ },
562
+ "handlebars_attribute_value": {
563
+ "begin": "\\b([\\.a-zA-Z0-9_-]+)\\b\\s*",
564
+ "captures": {
565
+ "1": {
566
+ "name": "variable.parameter.handlebars"
567
+ }
568
+ },
569
+ "end": "('|\"|)",
570
+ "name": "entity.other.attribute-value.handlebars",
564
571
  "patterns": [
565
572
  {
566
573
  "include": "#string"
567
574
  }
568
575
  ]
569
576
  },
577
+ "handlebars_attribute": {
578
+ "patterns": [
579
+ {
580
+ "include": "#handlebars_attribute_name"
581
+ },
582
+ {
583
+ "include": "#handlebars_attribute_value"
584
+ }
585
+ ]
586
+ },
570
587
  "extends": {
571
588
  "patterns": [
572
589
  {
@@ -1,162 +1,269 @@
1
1
  {
2
- "comment": "Syntax highlighting for reStructuredText: http://docutils.sourceforge.net",
2
+ "name": "reStructuredText",
3
+ "scopeName": "text.restructuredtext",
3
4
  "fileTypes": [
4
5
  "rst",
5
6
  "rest"
6
7
  ],
7
- "keyEquivalent": "^~R",
8
- "name": "reStructuredText",
9
8
  "patterns": [
10
9
  {
11
- "begin": "^([ \\t]*)(?=\\S)",
12
- "contentName": "meta.paragraph.restructuredtext",
13
- "end": "^(?!\\1)",
14
- "patterns": [
15
- {
16
- "include": "#all"
17
- }
18
- ]
10
+ "include": "#all"
19
11
  }
20
12
  ],
21
13
  "repository": {
22
14
  "all": {
23
15
  "patterns": [
16
+ {
17
+ "include": "#escape"
18
+ },
19
+ {
20
+ "include": "#line-blocks"
21
+ },
22
+ {
23
+ "include": "#tables"
24
+ },
25
+ {
26
+ "include": "#headings"
27
+ },
28
+ {
29
+ "include": "#substitution-definition"
30
+ },
24
31
  {
25
32
  "include": "#directives"
26
33
  },
27
34
  {
28
35
  "include": "#raw-blocks"
29
36
  },
37
+ {
38
+ "include": "#inlines"
39
+ },
40
+ {
41
+ "include": "#tag-name"
42
+ },
43
+ {
44
+ "include": "#doctests"
45
+ },
46
+ {
47
+ "include": "#domains"
48
+ },
49
+ {
50
+ "include": "#comments"
51
+ }
52
+ ]
53
+ },
54
+ "inlines": {
55
+ "patterns": [
56
+ {
57
+ "include": "#escape"
58
+ },
30
59
  {
31
60
  "include": "#emphasis"
32
61
  },
33
62
  {
34
- "include": "#link-def"
63
+ "include": "#link-definition"
35
64
  },
36
65
  {
37
- "captures": {
38
- "1": {
39
- "name": "punctuation.definition.substitution.restructuredtext"
40
- }
41
- },
42
- "comment": "substitution",
43
- "match": "(\\|)[^|]+(\\|_{0,2})",
44
- "name": "markup.underline.substitution.restructuredtext"
66
+ "include": "#substitution"
45
67
  },
46
68
  {
47
- "begin": "``",
48
- "captures": {
49
- "0": {
50
- "name": "punctuation.definition.raw.restructuredtext"
51
- }
52
- },
53
- "comment": "inline literal",
54
- "end": "``((?=[^`\\w\\d])|$)",
55
- "name": "markup.raw.restructuredtext"
69
+ "include": "#literal"
56
70
  },
57
71
  {
58
- "captures": {
59
- "1": {
60
- "name": "punctuation.definition.intepreted.restructuredtext"
61
- },
62
- "2": {
63
- "name": "punctuation.definition.intepreted.restructuredtext"
64
- }
65
- },
66
- "comment": "intepreted text - single line",
67
- "match": "(`)[^`]+(`)(?!_)",
68
- "name": "markup.other.command.restructuredtext"
72
+ "include": "#interpreted-line"
69
73
  },
70
74
  {
71
- "captures": {
72
- "1": {
73
- "name": "punctuation.definition.link.restructuredtext"
74
- },
75
- "2": {
76
- "name": "markup.underline.link.restructuredtext"
77
- }
78
- },
79
- "comment": "anonymous links __ url",
80
- "match": "\\s*(__)\\s+(.+)",
81
- "name": "meta.link.restructuredtext"
75
+ "include": "#anonymous-link"
82
76
  },
83
77
  {
84
78
  "include": "#link-reference"
85
79
  },
86
80
  {
87
- "begin": "(:)([-A-z0-9_.]*)(:)(`)",
88
- "beginCaptures": {
81
+ "include": "#interpreted-block"
82
+ },
83
+ {
84
+ "include": "#link-text"
85
+ },
86
+ {
87
+ "include": "#footnotes"
88
+ },
89
+ {
90
+ "include": "#citations"
91
+ }
92
+ ]
93
+ },
94
+ "escape": {
95
+ "match": "\\\\.",
96
+ "name": "constant.character.escape.backslash.restructuredtext"
97
+ },
98
+ "uri": {
99
+ "name": "string.other.uri.restructuredtext",
100
+ "match": "\\S+",
101
+ "captures": {
102
+ "0": {
103
+ "name": "markup.link.underline.restructuredtext"
104
+ }
105
+ }
106
+ },
107
+ "length": {
108
+ "name": "constant.numeric.length.restructuredtext",
109
+ "match": "[\\d.]+\\s*(?i:(em|ex|px|in|cm|mm|pt|pc)|(%))?",
110
+ "captures": {
111
+ "1": {
112
+ "name": "keyword.other.${1:/downcase}-unit.restructuredtext"
113
+ },
114
+ "2": {
115
+ "name": "keyword.other.percentile-unit.restructuredtext"
116
+ }
117
+ }
118
+ },
119
+ "headings": {
120
+ "name": "markup.heading.restructuredtext",
121
+ "match": "^[-=~`#\"^+*:.'_]{3,}\\s*$",
122
+ "captures": {
123
+ "0": {
124
+ "name": "punctuation.definition.heading.restructuredtext"
125
+ }
126
+ }
127
+ },
128
+ "line-blocks": {
129
+ "name": "meta.line-block.restructuredtext",
130
+ "begin": "^(\\s*)(\\|)(?!.*?(?<=\\S)\\|)",
131
+ "end": "^(?=\\s*$\\n?)",
132
+ "beginCaptures": {
133
+ "2": {
134
+ "name": "punctuation.separator.line-block.restructuredtext"
135
+ }
136
+ },
137
+ "patterns": [
138
+ {
139
+ "match": "^\\s*(\\|)",
140
+ "captures": {
141
+ "0": {
142
+ "name": "punctuation.separator.line-block.restructuredtext"
143
+ }
144
+ }
145
+ },
146
+ {
147
+ "include": "#inlines"
148
+ }
149
+ ]
150
+ },
151
+ "emphasis": {
152
+ "patterns": [
153
+ {
154
+ "name": "markup.bold.restructuredtext",
155
+ "match": "(\\*\\*)[^\\*\\s][^*]*(\\*\\*)",
156
+ "captures": {
89
157
  "1": {
90
- "name": "punctuation.definition.intepreted.restructuredtext"
158
+ "name": "punctuation.definition.bold.restructuredtext"
91
159
  },
92
160
  "2": {
93
- "name": "entity.name.role.restructuredtext"
94
- },
95
- "3": {
96
- "name": "punctuation.definition.intepreted.restructuredtext"
97
- },
98
- "4": {
99
- "name": "punctuation.definition.intepreted.restructuredtext"
100
- }
101
- },
102
- "comment": "intepreted text - multiline with role",
103
- "contentName": "string.other.interpreted.restructuredtext",
104
- "end": "(`)",
105
- "endCaptures": {
106
- "1": {
107
- "name": "punctuation.definition.intepreted.restructuredtext"
161
+ "name": "punctuation.definition.bold.restructuredtext"
108
162
  }
109
- },
110
- "name": "markup.other.command.restructuredtext"
163
+ }
111
164
  },
112
165
  {
166
+ "name": "markup.italic.restructuredtext",
167
+ "match": "(?<!\\\\)(\\*)[^\\*\\s][^*]*(?<!\\\\)(\\*)",
113
168
  "captures": {
114
169
  "1": {
115
- "name": "punctuation.definition.link.restructuredtext"
170
+ "name": "punctuation.definition.italic.restructuredtext"
116
171
  },
117
172
  "2": {
118
- "name": "string.other.link.title.restructuredtext"
119
- },
120
- "3": {
121
- "name": "punctuation.definition.location.restructuredtext"
122
- },
123
- "4": {
124
- "name": "markup.underline.link.restructuredtext"
125
- },
126
- "5": {
127
- "name": "punctuation.definition.location.restructuredtext"
128
- },
129
- "6": {
130
- "name": "punctuation.definition.link.restructuredtext"
173
+ "name": "punctuation.definition.italic.restructuredtext"
131
174
  }
132
- },
133
- "comment": "links `...`_ ",
134
- "match": "(`)([^<`]+)\\s+(<)(.*?)(>)(`_)",
135
- "name": "meta.link.inline.restructuredtext"
175
+ }
176
+ }
177
+ ]
178
+ },
179
+ "literal": {
180
+ "name": "markup.raw.restructuredtext",
181
+ "begin": "``",
182
+ "end": "``((?=[^`\\w\\d])|$)",
183
+ "captures": {
184
+ "0": {
185
+ "name": "punctuation.definition.raw.restructuredtext"
186
+ }
187
+ }
188
+ },
189
+ "interpreted-block": {
190
+ "name": "markup.other.command.restructuredtext",
191
+ "contentName": "string.other.interpreted.restructuredtext",
192
+ "begin": "(:)([-A-z0-9:_.]*)(:)(`)",
193
+ "end": "(`)",
194
+ "beginCaptures": {
195
+ "1": {
196
+ "name": "punctuation.definition.intepreted.restructuredtext"
136
197
  },
137
- {
138
- "include": "#footnotes"
198
+ "2": {
199
+ "name": "entity.name.role.restructuredtext"
139
200
  },
140
- {
141
- "include": "#citations"
201
+ "3": {
202
+ "name": "punctuation.definition.intepreted.restructuredtext"
142
203
  },
143
- {
144
- "include": "#tags"
204
+ "4": {
205
+ "name": "punctuation.definition.intepreted.restructuredtext"
206
+ }
207
+ },
208
+ "endCaptures": {
209
+ "1": {
210
+ "name": "punctuation.definition.intepreted.restructuredtext"
211
+ }
212
+ }
213
+ },
214
+ "interpreted-line": {
215
+ "name": "markup.other.command.restructuredtext",
216
+ "match": "(`)[^`]+(`)(?!_)",
217
+ "captures": {
218
+ "1": {
219
+ "name": "punctuation.definition.intepreted.restructuredtext"
145
220
  },
146
- {
147
- "include": "#tables"
221
+ "2": {
222
+ "name": "punctuation.definition.intepreted.restructuredtext"
223
+ }
224
+ }
225
+ },
226
+ "anonymous-link": {
227
+ "name": "meta.link.restructuredtext",
228
+ "match": "\\s*(__)\\s+(.+)",
229
+ "captures": {
230
+ "1": {
231
+ "name": "punctuation.definition.link.restructuredtext"
148
232
  },
149
- {
150
- "include": "#headings"
233
+ "2": {
234
+ "name": "markup.underline.link.restructuredtext"
235
+ }
236
+ }
237
+ },
238
+ "link-text": {
239
+ "name": "meta.link.inline.restructuredtext",
240
+ "match": "(`)([^<`]+)\\s+(<)(.*?)(>)(`_)",
241
+ "captures": {
242
+ "1": {
243
+ "name": "punctuation.definition.link.restructuredtext"
151
244
  },
152
- {
153
- "include": "#comments"
245
+ "2": {
246
+ "name": "string.other.link.title.restructuredtext"
247
+ },
248
+ "3": {
249
+ "name": "punctuation.definition.location.restructuredtext"
250
+ },
251
+ "4": {
252
+ "name": "markup.underline.link.restructuredtext"
253
+ },
254
+ "5": {
255
+ "name": "punctuation.definition.location.restructuredtext"
256
+ },
257
+ "6": {
258
+ "name": "punctuation.definition.link.restructuredtext"
154
259
  }
155
- ]
260
+ }
156
261
  },
157
262
  "citations": {
158
263
  "patterns": [
159
264
  {
265
+ "name": "meta.link.citation.def.restructuredtext",
266
+ "match": "^(\\.\\.)\\s+((\\[)[A-z][A-z0-9]*(\\]))(_)\\s+(.*)",
160
267
  "captures": {
161
268
  "1": {
162
269
  "name": "punctuation.definition.link.restructuredtext"
@@ -176,12 +283,11 @@
176
283
  "6": {
177
284
  "name": "string.other.citation.restructuredtext"
178
285
  }
179
- },
180
- "comment": "replacement",
181
- "match": "^(\\.\\.)\\s+((\\[)[A-z][A-z0-9]*(\\]))(_)\\s+(.*)",
182
- "name": "meta.link.citation.def.restructuredtext"
286
+ }
183
287
  },
184
288
  {
289
+ "name": "meta.link.citation.restructuredtext",
290
+ "match": "((\\[)[A-z][A-z0-9_-]*(\\]))(_)",
185
291
  "captures": {
186
292
  "1": {
187
293
  "name": "constant.other.citation.link.restructuredtext"
@@ -195,143 +301,89 @@
195
301
  "4": {
196
302
  "name": "punctuation.definition.constant.restructuredtext"
197
303
  }
198
- },
199
- "comment": "citation reference",
200
- "match": "((\\[)[A-z][A-z0-9_-]*(\\]))(_)",
201
- "name": "meta.link.citation.restructuredtext"
304
+ }
202
305
  }
203
306
  ]
204
307
  },
205
308
  "comments": {
206
309
  "patterns": [
207
310
  {
208
- "begin": "^(\\.\\.)[ ]",
311
+ "name": "comment.block.empty-start.double-dot.restructuredtext",
312
+ "begin": "^(\\.\\.)[\\t ]*$\\n?",
313
+ "end": "^(?<=\\G)\\s*$\\n?|^(?=\\S)",
209
314
  "beginCaptures": {
210
315
  "1": {
211
316
  "name": "punctuation.definition.comment.restructuredtext"
212
317
  }
213
318
  },
214
- "end": "^[\\s]*$\\n?",
215
- "name": "comment.line.double-dot.restructuredtext"
216
- }
217
- ]
218
- },
219
- "directives": {
220
- "patterns": [
221
- {
222
- "begin": "^([ \\t]*)((\\.\\.)\\sraw(::)) html",
223
- "captures": {
224
- "2": {
225
- "name": "meta.directive.restructuredtext"
226
- },
227
- "3": {
228
- "name": "punctuation.definition.directive.restructuredtext"
229
- },
230
- "4": {
231
- "name": "punctuation.separator.key-value.restructuredtext"
232
- }
233
- },
234
- "comment": "directives.html",
235
- "end": "^(?!\\1[ \\t])",
236
319
  "patterns": [
237
320
  {
238
- "include": "text.html.basic"
321
+ "begin": "^(\\s+).*?\\S+\\s*$\\n",
322
+ "end": "^\\s*$\\n|^(?=\\S)"
239
323
  }
240
324
  ]
241
325
  },
242
326
  {
243
- "captures": {
244
- "1": {
245
- "name": "punctuation.definition.directive.restructuredtext"
246
- },
247
- "2": {
248
- "name": "support.directive.restructuredtext"
249
- },
250
- "3": {
251
- "name": "punctuation.separator.key-value.restructuredtext"
252
- }
253
- },
254
- "comment": "directives",
255
- "match": "(\\.\\.)\\s([A-z][-A-z0-9_]+)(::)\\s*$",
256
- "name": "meta.other.directive.restructuredtext"
257
- },
258
- {
259
- "captures": {
260
- "1": {
261
- "name": "punctuation.definition.directive.restructuredtext"
262
- },
327
+ "name": "comment.block.empty-start.double-dot.restructuredtext",
328
+ "begin": "^([\\t ]*)(\\.\\.)[\\t ]*$\\n?",
329
+ "end": "^(?!\\1\\s*\\S)|^(?<!\\G)\\s*$\\n?|^(?=\\S)",
330
+ "beginCaptures": {
263
331
  "2": {
264
- "name": "support.directive.restructuredtext"
265
- },
266
- "3": {
267
- "name": "punctuation.separator.key-value.restructuredtext"
268
- },
269
- "4": {
270
- "name": "entity.name.directive.restructuredtext"
332
+ "name": "punctuation.definition.comment.restructuredtext"
271
333
  }
272
334
  },
273
- "comment": "directives with arguments",
274
- "match": "(\\.\\.)\\s([A-z][-A-z0-9_]+)(::)\\s+(.+?)\\s*$",
275
- "name": "meta.other.directive.restructuredtext"
276
- }
277
- ]
278
- },
279
- "emphasis": {
280
- "patterns": [
281
- {
282
- "captures": {
283
- "1": {
284
- "name": "punctuation.definition.bold.restructuredtext"
285
- },
286
- "2": {
287
- "name": "punctuation.definition.bold.restructuredtext"
335
+ "patterns": [
336
+ {
337
+ "begin": "^(\\s+).*?\\S+\\s*$\\n",
338
+ "end": "^\\s*$\\n|^\\s*(?=\\S)"
288
339
  }
289
- },
290
- "match": "(\\*\\*)[^*]+(\\*\\*)",
291
- "name": "markup.bold.restructuredtext"
340
+ ]
292
341
  },
293
342
  {
294
- "captures": {
295
- "1": {
296
- "name": "punctuation.definition.italic.restructuredtext"
297
- },
343
+ "name": "comment.block.double-dot.restructuredtext",
344
+ "begin": "^(\\s*)(\\.\\.)(?=\\s|$)",
345
+ "end": "^(?!\\1[\\t\\s]+\\S|\\s*$)|^(?=\\S)",
346
+ "beginCaptures": {
298
347
  "2": {
299
- "name": "punctuation.definition.italic.restructuredtext"
348
+ "name": "punctuation.definition.comment.restructuredtext"
300
349
  }
301
- },
302
- "match": "(\\*)\\w[^*]+\\w(\\*)",
303
- "name": "markup.italic.restructuredtext"
350
+ }
304
351
  }
305
352
  ]
306
353
  },
307
354
  "footnotes": {
308
355
  "patterns": [
309
356
  {
357
+ "name": "meta.link.footnote.def.restructuredtext",
358
+ "begin": "^(\\s*)(\\.\\.)\\s+((\\[)(((#?)[^\\]]*?)|\\*)(\\]))\\s+",
359
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
360
+ "patterns": [
361
+ {
362
+ "include": "#inlines"
363
+ }
364
+ ],
365
+ "contentName": "string.other.footnote.restructuredtext",
310
366
  "captures": {
311
- "1": {
312
- "name": "punctuation.definition.link.restructuredtext"
313
- },
314
367
  "2": {
315
- "name": "constant.other.footnote.link.restructuredtext"
368
+ "name": "punctuation.definition.link.restructuredtext"
316
369
  },
317
370
  "3": {
318
- "name": "punctuation.definition.constant.restructuredtext"
371
+ "name": "constant.other.footnote.link.restructuredtext"
319
372
  },
320
- "6": {
373
+ "4": {
321
374
  "name": "punctuation.definition.constant.restructuredtext"
322
375
  },
323
376
  "7": {
324
377
  "name": "punctuation.definition.constant.restructuredtext"
325
378
  },
326
379
  "8": {
327
- "name": "string.other.footnote.restructuredtext"
380
+ "name": "punctuation.definition.constant.restructuredtext"
328
381
  }
329
- },
330
- "comment": "replacement",
331
- "match": "^(\\.\\.)\\s+((\\[)(((#?)[^]]*?)|\\*)(\\]))\\s+(.*)",
332
- "name": "meta.link.footnote.def.restructuredtext"
382
+ }
333
383
  },
334
384
  {
385
+ "name": "meta.link.footnote.numeric.restructuredtext",
386
+ "match": "((\\[)[0-9]+(\\]))(_)",
335
387
  "captures": {
336
388
  "1": {
337
389
  "name": "constant.other.footnote.link"
@@ -345,12 +397,11 @@
345
397
  "4": {
346
398
  "name": "punctuation.definition.constant.restructuredtext"
347
399
  }
348
- },
349
- "comment": "footnote reference: [0]_",
350
- "match": "((\\[)[0-9]+(\\]))(_)",
351
- "name": "meta.link.footnote.numeric.restructuredtext"
400
+ }
352
401
  },
353
402
  {
403
+ "name": "meta.link.footnote.auto.restructuredtext",
404
+ "match": "((\\[#)[A-z0-9_]*(\\]))(_)",
354
405
  "captures": {
355
406
  "1": {
356
407
  "name": "constant.other.footnote.link"
@@ -364,12 +415,11 @@
364
415
  "4": {
365
416
  "name": "punctuation.definition.constant.restructuredtext"
366
417
  }
367
- },
368
- "comment": "footnote reference [#]_ or [#foo]_",
369
- "match": "((\\[#)[A-z0-9_]*(\\]))(_)",
370
- "name": "meta.link.footnote.auto.restructuredtext"
418
+ }
371
419
  },
372
420
  {
421
+ "name": "meta.link.footnote.symbol.auto.restructuredtext",
422
+ "match": "((\\[)\\*(\\]))(_)",
373
423
  "captures": {
374
424
  "1": {
375
425
  "name": "constant.other.footnote.link.restructuredtext"
@@ -383,29 +433,15 @@
383
433
  "4": {
384
434
  "name": "punctuation.definition.constant.restructuredtext"
385
435
  }
386
- },
387
- "comment": "footnote reference [*]_",
388
- "match": "((\\[)\\*(\\]))(_)",
389
- "name": "meta.link.footnote.symbol.auto.restructuredtext"
390
- }
391
- ]
392
- },
393
- "headings": {
394
- "patterns": [
395
- {
396
- "captures": {
397
- "1": {
398
- "name": "punctuation.definition.heading.restructuredtext"
399
- }
400
- },
401
- "match": "(^(=|-|~|`|#|\"|\\^|\\+|\\*){3,}$){1,1}?",
402
- "name": "markup.heading.restructuredtext"
436
+ }
403
437
  }
404
438
  ]
405
439
  },
406
- "link-def": {
440
+ "link-definition": {
407
441
  "patterns": [
408
442
  {
443
+ "name": "meta.link.reference.def.restructuredtext",
444
+ "match": "(\\.\\.)\\s+(_)([-.\\d\\w\\s()/]+)(:)\\s+(.*)",
409
445
  "captures": {
410
446
  "1": {
411
447
  "name": "punctuation.definition.link.restructuredtext"
@@ -420,14 +456,17 @@
420
456
  "name": "punctuation.separator.key-value.restructuredtext"
421
457
  },
422
458
  "5": {
423
- "name": "markup.underline.link.restructuredtext"
459
+ "patterns": [
460
+ {
461
+ "include": "#uri"
462
+ }
463
+ ]
424
464
  }
425
- },
426
- "comment": "replacement",
427
- "match": "(\\.\\.)\\s+(_)([-.\\d\\w\\s()]+)(:)\\s+(.*)",
428
- "name": "meta.link.reference.def.restructuredtext"
465
+ }
429
466
  },
430
467
  {
468
+ "name": "meta.link.reference.def.restructuredtext",
469
+ "match": "(\\.\\.)\\s+(_`)([^`]+)(`:)\\s+(.*)",
431
470
  "captures": {
432
471
  "1": {
433
472
  "name": "punctuation.definition.link.restructuredtext"
@@ -442,18 +481,21 @@
442
481
  "name": "punctuation.separator.key-value.restructuredtext"
443
482
  },
444
483
  "5": {
445
- "name": "markup.underline.link.restructuredtext"
484
+ "patterns": [
485
+ {
486
+ "include": "#uri"
487
+ }
488
+ ]
446
489
  }
447
- },
448
- "comment": "replacement",
449
- "match": "(\\.\\.)\\s+(_`)([^`]+)(`:)\\s+(.*)",
450
- "name": "meta.link.reference.def.restructuredtext"
490
+ }
451
491
  }
452
492
  ]
453
493
  },
454
494
  "link-reference": {
455
495
  "patterns": [
456
496
  {
497
+ "name": "meta.link.reference",
498
+ "match": "\\b([-.:+_\\d\\w]+)(_)\\b",
457
499
  "captures": {
458
500
  "1": {
459
501
  "name": "string.other.link.title.restructuredtext"
@@ -461,101 +503,1021 @@
461
503
  "2": {
462
504
  "name": "punctuation.definition.link.restructuredtext"
463
505
  }
464
- },
465
- "match": "\\b([-.:+_\\d\\w]+)(_)\\b",
466
- "name": "meta.link.reference"
506
+ }
467
507
  },
468
508
  {
509
+ "name": "meta.link.reference",
469
510
  "begin": "(`)",
511
+ "end": "(`_)",
470
512
  "beginCaptures": {
471
513
  "1": {
472
514
  "name": "punctuation.definition.link.restructuredtext"
473
515
  }
474
516
  },
475
- "end": "(`_)",
476
517
  "endCaptures": {
477
518
  "1": {
478
519
  "name": "punctuation.definition.link.restructuredtext"
479
520
  }
480
521
  },
481
- "name": "meta.link.reference",
482
522
  "patterns": [
483
523
  {
484
- "match": "[^`]+",
485
- "name": "string.other.link.title.restructuredtext"
524
+ "name": "string.other.link.title.restructuredtext",
525
+ "match": "[^`]+"
486
526
  }
487
527
  ]
488
528
  }
489
529
  ]
490
530
  },
491
531
  "raw-blocks": {
532
+ "contentName": "meta.raw.block.restructuredtext",
492
533
  "patterns": [
493
534
  {
494
- "begin": "(::)$",
495
- "beginCaptures": {
496
- "1": {
497
- "name": "punctuation.section.raw.restructuredtext"
535
+ "name": "markup.raw.inner.restructuredtext",
536
+ "match": ".+"
537
+ }
538
+ ],
539
+ "begin": "^(?!\\s*\\.\\.\\s\\w+)(\\s*)(.*)(::)$",
540
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
541
+ "beginCaptures": {
542
+ "2": {
543
+ "patterns": [
544
+ {
545
+ "include": "#inlines"
498
546
  }
499
- },
500
- "comment": "Literal Blocks",
501
- "contentName": "meta.raw.block.restructuredtext",
502
- "end": "^(?=\\S)",
547
+ ]
548
+ },
549
+ "3": {
550
+ "name": "punctuation.section.raw.restructuredtext"
551
+ }
552
+ }
553
+ },
554
+ "doctests": {
555
+ "name": "meta.doctest.restructuredtext",
556
+ "begin": "^(\\s*)(>>>)\\s+(.*)$\\n",
557
+ "end": "^\\s*$|^(?=\\1>>> )|^(?=>>>)|^(?!\\1)\\s+\\S",
558
+ "contentName": "markup.raw.restructuredtext",
559
+ "beginCaptures": {
560
+ "2": {
561
+ "name": "punctuation.separator.prompt.doctest.restructuredtext"
562
+ },
563
+ "3": {
503
564
  "patterns": [
504
565
  {
505
- "include": "#raw-blocks-inner"
566
+ "include": "source.python"
506
567
  }
507
568
  ]
508
569
  }
509
- ]
570
+ }
510
571
  },
511
- "raw-blocks-inner": {
572
+ "tables": {
512
573
  "patterns": [
513
574
  {
514
- "match": ".+",
515
- "name": "markup.raw.inner.restructuredtext"
575
+ "name": "meta.table.grid-table.restructuredtext",
576
+ "contentName": "markup.other.table.restructuredtext",
577
+ "begin": "(?=((\\+-[+-]+))|((\\+=[+=]+))\\s*$)",
578
+ "end": "^\\s*$",
579
+ "patterns": [
580
+ {
581
+ "include": "#table-borders"
582
+ },
583
+ {
584
+ "include": "#inlines"
585
+ }
586
+ ]
587
+ },
588
+ {
589
+ "name": "punctuation.definition.table.simple-divider.restructuredtext",
590
+ "match": "(?x)\n^\\s*-{2,}\\s+-{2,}(?:\\s+-{2,})*\\s*$\n|\n^\\s*={2,}\\s+={2,}(?:\\s+={2,})*\\s*$"
516
591
  }
517
592
  ]
518
593
  },
519
- "tables": {
594
+ "table-borders": {
520
595
  "patterns": [
521
596
  {
522
- "captures": {
597
+ "begin": "\\+(?=-+(?=\\+|$))",
598
+ "end": "(?=\\+(?=-)|$)|\\+(?=\\s|$)",
599
+ "contentName": "punctuation.definition.table.row-divider.restructuredtext",
600
+ "beginCaptures": {
523
601
  "0": {
524
- "name": "punctuation.definition.table.restructuredtext"
602
+ "name": "punctuation.definition.table.joint.restructuredtext"
525
603
  }
526
604
  },
527
- "match": "\\+-[+-]+",
528
- "name": "markup.other.table.restructuredtext"
605
+ "endCaptures": {
606
+ "0": {
607
+ "name": "punctuation.definition.table.joint.restructuredtext"
608
+ }
609
+ }
529
610
  },
530
611
  {
531
- "captures": {
612
+ "begin": "\\+(?==+(?=\\+|$))",
613
+ "end": "(?=\\+(?==)|$)|\\+\\s*$",
614
+ "contentName": "punctuation.definition.table.header.row-divider.restructuredtext",
615
+ "beginCaptures": {
532
616
  "0": {
533
- "name": "punctuation.definition.table.restructuredtext"
617
+ "name": "punctuation.definition.table.joint.restructuredtext"
534
618
  }
535
619
  },
536
- "match": "\\+=[+=]+",
537
- "name": "markup.other.table.restructuredtext"
620
+ "endCaptures": {
621
+ "0": {
622
+ "name": "punctuation.definition.table.joint.restructuredtext"
623
+ }
624
+ }
625
+ },
626
+ {
627
+ "match": "\\|",
628
+ "name": "punctuation.definition.table.header.column-divider.restructuredtext"
538
629
  }
539
630
  ]
540
631
  },
541
- "tags": {
632
+ "tag-name": {
633
+ "name": "entity.name.tag.restructuredtext",
634
+ "match": "(:)[A-Za-z][\\w\\s=.]*(:)",
635
+ "captures": {
636
+ "1": {
637
+ "name": "punctuation.definition.field.restructuredtext"
638
+ },
639
+ "2": {
640
+ "name": "punctuation.definition.field.restructuredtext"
641
+ }
642
+ }
643
+ },
644
+ "substitution": {
645
+ "name": "support.variable.substitution.restructuredtext",
646
+ "match": "(?<!\\\\)(\\|)[^|]+(?<!\\\\)(\\|_{0,2})",
647
+ "captures": {
648
+ "1": {
649
+ "name": "punctuation.definition.substitution.restructuredtext"
650
+ },
651
+ "2": {
652
+ "name": "punctuation.definition.substitution.restructuredtext"
653
+ }
654
+ }
655
+ },
656
+ "substitution-definition": {
542
657
  "patterns": [
543
658
  {
544
- "captures": {
545
- "1": {
546
- "name": "punctuation.definition.field.restructuredtext"
659
+ "name": "meta.substitution-definition.image.restructuredtext",
660
+ "begin": "^(\\s*)(\\.\\.)\\s(\\|)(?=\\S)([^\\|]+)((?<=\\S)\\|)\\s+(image)(::)\\s*(\\S+)",
661
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
662
+ "patterns": [
663
+ {
664
+ "include": "#image-options"
665
+ }
666
+ ],
667
+ "beginCaptures": {
668
+ "2": {
669
+ "name": "punctuation.definition.directive.restructuredtext"
670
+ },
671
+ "3": {
672
+ "name": "punctuation.definition.substitution.start.restructuredtext"
673
+ },
674
+ "4": {
675
+ "name": "entity.name.substitution.restructuredtext"
676
+ },
677
+ "5": {
678
+ "name": "punctuation.definition.substitution.end.restructuredtext"
679
+ },
680
+ "6": {
681
+ "name": "support.directive.restructuredtext"
682
+ },
683
+ "7": {
684
+ "name": "punctuation.separator.key-value.restructuredtext"
547
685
  },
686
+ "8": {
687
+ "patterns": [
688
+ {
689
+ "include": "#uri"
690
+ }
691
+ ]
692
+ }
693
+ }
694
+ },
695
+ {
696
+ "name": "meta.substitution-definition.restructuredtext",
697
+ "begin": "^(\\s*)(\\.\\.)\\s(\\|)(?=\\S)([^\\|]+)((?<=\\S)\\|)\\s+(\\S+.*(?=::))(::)(.*)",
698
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
699
+ "patterns": [
700
+ {
701
+ "include": "#directive-options"
702
+ }
703
+ ],
704
+ "beginCaptures": {
548
705
  "2": {
549
- "name": "punctuation.definition.field.restructuredtext"
706
+ "name": "punctuation.definition.directive.restructuredtext"
707
+ },
708
+ "3": {
709
+ "name": "punctuation.definition.substitution.start.restructuredtext"
710
+ },
711
+ "4": {
712
+ "name": "entity.name.substitution.restructuredtext"
713
+ },
714
+ "5": {
715
+ "name": "punctuation.definition.substitution.end.restructuredtext"
716
+ },
717
+ "6": {
718
+ "name": "support.directive.restructuredtext"
719
+ },
720
+ "7": {
721
+ "name": "punctuation.separator.key-value.restructuredtext"
722
+ },
723
+ "8": {
724
+ "name": "string.unquoted.substitution.data.restructuredtext"
550
725
  }
551
- },
552
- "comment": "tags (and field lists",
553
- "match": "(:)[A-z][A-z0-9 =\\s\\t_.]*(:)",
554
- "name": "entity.name.tag.restructuredtext"
726
+ }
555
727
  }
556
728
  ]
557
- }
558
- },
559
- "scopeName": "text.restructuredtext",
560
- "uuid": "62DA9AD6-36E1-4AB7-BB87-E933AD9FD1A4"
729
+ },
730
+ "directives": {
731
+ "patterns": [
732
+ {
733
+ "name": "meta.image.restructuredtext",
734
+ "begin": "^(\\s*)(\\.\\.)\\s(image)(::)\\s*(\\S+)",
735
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
736
+ "patterns": [
737
+ {
738
+ "include": "#image-options"
739
+ }
740
+ ],
741
+ "beginCaptures": {
742
+ "2": {
743
+ "name": "punctuation.definition.directive.restructuredtext"
744
+ },
745
+ "3": {
746
+ "name": "support.directive.restructuredtext"
747
+ },
748
+ "4": {
749
+ "name": "punctuation.separator.key-value.restructuredtext"
750
+ },
751
+ "5": {
752
+ "patterns": [
753
+ {
754
+ "include": "#uri"
755
+ }
756
+ ]
757
+ }
758
+ }
759
+ },
760
+ {
761
+ "name": "meta.figure.restructuredtext",
762
+ "begin": "^(\\s*)(\\.\\.)\\s(figure)(::)\\s*(\\S+)",
763
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
764
+ "patterns": [
765
+ {
766
+ "include": "#image-options"
767
+ },
768
+ {
769
+ "include": "#all"
770
+ }
771
+ ],
772
+ "beginCaptures": {
773
+ "2": {
774
+ "name": "punctuation.definition.directive.restructuredtext"
775
+ },
776
+ "3": {
777
+ "name": "support.directive.restructuredtext"
778
+ },
779
+ "4": {
780
+ "name": "punctuation.separator.key-value.restructuredtext"
781
+ },
782
+ "5": {
783
+ "patterns": [
784
+ {
785
+ "include": "#uri"
786
+ }
787
+ ]
788
+ }
789
+ }
790
+ },
791
+ {
792
+ "begin": "^([ \\t]*)(\\.\\.)\\s(raw)(::)\\s+(html)\\s*$",
793
+ "end": "^(?!\\1[ \\t])",
794
+ "patterns": [
795
+ {
796
+ "include": "text.html.basic"
797
+ }
798
+ ],
799
+ "beginCaptures": {
800
+ "2": {
801
+ "name": "punctuation.definition.directive.restructuredtext"
802
+ },
803
+ "3": {
804
+ "name": "support.directive.restructuredtext"
805
+ },
806
+ "4": {
807
+ "name": "punctuation.separator.key-value.restructuredtext"
808
+ },
809
+ "5": {
810
+ "name": "entity.name.directive.restructuredtext"
811
+ }
812
+ }
813
+ },
814
+ {
815
+ "contentName": "source.embedded.coffee",
816
+ "patterns": [
817
+ {
818
+ "include": "source.coffee"
819
+ }
820
+ ],
821
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(coffee-?script)\\s*$",
822
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
823
+ "beginCaptures": {
824
+ "2": {
825
+ "name": "punctuation.definition.directive.restructuredtext"
826
+ },
827
+ "3": {
828
+ "name": "support.directive.restructuredtext"
829
+ },
830
+ "4": {
831
+ "name": "punctuation.separator.key-value.restructuredtext"
832
+ },
833
+ "5": {
834
+ "name": "entity.name.directive.restructuredtext"
835
+ }
836
+ }
837
+ },
838
+ {
839
+ "contentName": "source.embedded.js",
840
+ "patterns": [
841
+ {
842
+ "include": "source.js"
843
+ }
844
+ ],
845
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(js|javascript)\\s*$",
846
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
847
+ "beginCaptures": {
848
+ "2": {
849
+ "name": "punctuation.definition.directive.restructuredtext"
850
+ },
851
+ "3": {
852
+ "name": "support.directive.restructuredtext"
853
+ },
854
+ "4": {
855
+ "name": "punctuation.separator.key-value.restructuredtext"
856
+ },
857
+ "5": {
858
+ "name": "entity.name.directive.restructuredtext"
859
+ }
860
+ }
861
+ },
862
+ {
863
+ "contentName": "source.embedded.json",
864
+ "patterns": [
865
+ {
866
+ "include": "source.json"
867
+ }
868
+ ],
869
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(json)\\s*$",
870
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
871
+ "beginCaptures": {
872
+ "2": {
873
+ "name": "punctuation.definition.directive.restructuredtext"
874
+ },
875
+ "3": {
876
+ "name": "support.directive.restructuredtext"
877
+ },
878
+ "4": {
879
+ "name": "punctuation.separator.key-value.restructuredtext"
880
+ },
881
+ "5": {
882
+ "name": "entity.name.directive.restructuredtext"
883
+ }
884
+ }
885
+ },
886
+ {
887
+ "contentName": "source.embedded.css",
888
+ "patterns": [
889
+ {
890
+ "include": "source.css"
891
+ }
892
+ ],
893
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(css)\\s*$",
894
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
895
+ "beginCaptures": {
896
+ "2": {
897
+ "name": "punctuation.definition.directive.restructuredtext"
898
+ },
899
+ "3": {
900
+ "name": "support.directive.restructuredtext"
901
+ },
902
+ "4": {
903
+ "name": "punctuation.separator.key-value.restructuredtext"
904
+ },
905
+ "5": {
906
+ "name": "entity.name.directive.restructuredtext"
907
+ }
908
+ }
909
+ },
910
+ {
911
+ "contentName": "source.embedded.xml",
912
+ "patterns": [
913
+ {
914
+ "include": "source.xml"
915
+ }
916
+ ],
917
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(xml)\\s*$",
918
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
919
+ "beginCaptures": {
920
+ "2": {
921
+ "name": "punctuation.definition.directive.restructuredtext"
922
+ },
923
+ "3": {
924
+ "name": "support.directive.restructuredtext"
925
+ },
926
+ "4": {
927
+ "name": "punctuation.separator.key-value.restructuredtext"
928
+ },
929
+ "5": {
930
+ "name": "entity.name.directive.restructuredtext"
931
+ }
932
+ }
933
+ },
934
+ {
935
+ "contentName": "source.embedded.ruby",
936
+ "patterns": [
937
+ {
938
+ "include": "source.ruby"
939
+ }
940
+ ],
941
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(ruby)\\s*$",
942
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
943
+ "beginCaptures": {
944
+ "2": {
945
+ "name": "punctuation.definition.directive.restructuredtext"
946
+ },
947
+ "3": {
948
+ "name": "support.directive.restructuredtext"
949
+ },
950
+ "4": {
951
+ "name": "punctuation.separator.key-value.restructuredtext"
952
+ },
953
+ "5": {
954
+ "name": "entity.name.directive.restructuredtext"
955
+ }
956
+ }
957
+ },
958
+ {
959
+ "contentName": "source.embedded.java",
960
+ "patterns": [
961
+ {
962
+ "include": "source.java"
963
+ }
964
+ ],
965
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(java)\\s*$",
966
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
967
+ "beginCaptures": {
968
+ "2": {
969
+ "name": "punctuation.definition.directive.restructuredtext"
970
+ },
971
+ "3": {
972
+ "name": "support.directive.restructuredtext"
973
+ },
974
+ "4": {
975
+ "name": "punctuation.separator.key-value.restructuredtext"
976
+ },
977
+ "5": {
978
+ "name": "entity.name.directive.restructuredtext"
979
+ }
980
+ }
981
+ },
982
+ {
983
+ "contentName": "source.embedded.erlang",
984
+ "patterns": [
985
+ {
986
+ "include": "source.erlang"
987
+ }
988
+ ],
989
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(erlang)\\s*$",
990
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
991
+ "beginCaptures": {
992
+ "2": {
993
+ "name": "punctuation.definition.directive.restructuredtext"
994
+ },
995
+ "3": {
996
+ "name": "support.directive.restructuredtext"
997
+ },
998
+ "4": {
999
+ "name": "punctuation.separator.key-value.restructuredtext"
1000
+ },
1001
+ "5": {
1002
+ "name": "entity.name.directive.restructuredtext"
1003
+ }
1004
+ }
1005
+ },
1006
+ {
1007
+ "contentName": "source.embedded.cs",
1008
+ "patterns": [
1009
+ {
1010
+ "include": "source.cs"
1011
+ }
1012
+ ],
1013
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(csharp|c#)\\s*$",
1014
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1015
+ "beginCaptures": {
1016
+ "2": {
1017
+ "name": "punctuation.definition.directive.restructuredtext"
1018
+ },
1019
+ "3": {
1020
+ "name": "support.directive.restructuredtext"
1021
+ },
1022
+ "4": {
1023
+ "name": "punctuation.separator.key-value.restructuredtext"
1024
+ },
1025
+ "5": {
1026
+ "name": "entity.name.directive.restructuredtext"
1027
+ }
1028
+ }
1029
+ },
1030
+ {
1031
+ "contentName": "source.embedded.php",
1032
+ "patterns": [
1033
+ {
1034
+ "include": "source.php"
1035
+ }
1036
+ ],
1037
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(php[3-5]?)\\s*$",
1038
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1039
+ "beginCaptures": {
1040
+ "2": {
1041
+ "name": "punctuation.definition.directive.restructuredtext"
1042
+ },
1043
+ "3": {
1044
+ "name": "support.directive.restructuredtext"
1045
+ },
1046
+ "4": {
1047
+ "name": "punctuation.separator.key-value.restructuredtext"
1048
+ },
1049
+ "5": {
1050
+ "name": "entity.name.directive.restructuredtext"
1051
+ }
1052
+ }
1053
+ },
1054
+ {
1055
+ "contentName": "source.embedded.shell",
1056
+ "patterns": [
1057
+ {
1058
+ "include": "source.shell"
1059
+ }
1060
+ ],
1061
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(shell|(ba|k)?sh)\\s*$",
1062
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1063
+ "beginCaptures": {
1064
+ "2": {
1065
+ "name": "punctuation.definition.directive.restructuredtext"
1066
+ },
1067
+ "3": {
1068
+ "name": "support.directive.restructuredtext"
1069
+ },
1070
+ "4": {
1071
+ "name": "punctuation.separator.key-value.restructuredtext"
1072
+ },
1073
+ "5": {
1074
+ "name": "entity.name.directive.restructuredtext"
1075
+ }
1076
+ }
1077
+ },
1078
+ {
1079
+ "contentName": "source.embedded.python",
1080
+ "patterns": [
1081
+ {
1082
+ "include": "source.python"
1083
+ }
1084
+ ],
1085
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(py(thon)?|sage)\\s*$",
1086
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1087
+ "beginCaptures": {
1088
+ "2": {
1089
+ "name": "punctuation.definition.directive.restructuredtext"
1090
+ },
1091
+ "3": {
1092
+ "name": "support.directive.restructuredtext"
1093
+ },
1094
+ "4": {
1095
+ "name": "punctuation.separator.key-value.restructuredtext"
1096
+ },
1097
+ "5": {
1098
+ "name": "entity.name.directive.restructuredtext"
1099
+ }
1100
+ }
1101
+ },
1102
+ {
1103
+ "contentName": "source.embedded.objc",
1104
+ "patterns": [
1105
+ {
1106
+ "include": "source.objc"
1107
+ }
1108
+ ],
1109
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(objective-?c|obj-?c)\\s*$",
1110
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1111
+ "beginCaptures": {
1112
+ "2": {
1113
+ "name": "punctuation.definition.directive.restructuredtext"
1114
+ },
1115
+ "3": {
1116
+ "name": "support.directive.restructuredtext"
1117
+ },
1118
+ "4": {
1119
+ "name": "punctuation.separator.key-value.restructuredtext"
1120
+ },
1121
+ "5": {
1122
+ "name": "entity.name.directive.restructuredtext"
1123
+ }
1124
+ }
1125
+ },
1126
+ {
1127
+ "contentName": "source.embedded.yaml",
1128
+ "patterns": [
1129
+ {
1130
+ "include": "source.yaml"
1131
+ }
1132
+ ],
1133
+ "begin": "^([ \\t]*)(\\.\\.)\\s(code(?:-block)?)(::)\\s+(yaml)\\s*$",
1134
+ "end": "^(?!\\s*$|\\1[ \\t]+\\S)",
1135
+ "beginCaptures": {
1136
+ "2": {
1137
+ "name": "punctuation.definition.directive.restructuredtext"
1138
+ },
1139
+ "3": {
1140
+ "name": "support.directive.restructuredtext"
1141
+ },
1142
+ "4": {
1143
+ "name": "punctuation.separator.key-value.restructuredtext"
1144
+ },
1145
+ "5": {
1146
+ "name": "entity.name.directive.restructuredtext"
1147
+ }
1148
+ }
1149
+ },
1150
+ {
1151
+ "name": "meta.other.directive.restructuredtext",
1152
+ "match": "^\\s*(\\.\\.)\\s([A-z][-A-z0-9_]+)(::)\\s*$",
1153
+ "captures": {
1154
+ "1": {
1155
+ "name": "punctuation.definition.directive.restructuredtext"
1156
+ },
1157
+ "2": {
1158
+ "name": "support.directive.restructuredtext"
1159
+ },
1160
+ "3": {
1161
+ "name": "punctuation.separator.key-value.restructuredtext"
1162
+ }
1163
+ }
1164
+ },
1165
+ {
1166
+ "name": "meta.other.directive.restructuredtext",
1167
+ "match": "^\\s*(\\.\\.)\\s([A-z][-A-z0-9_]+)(::)\\s+(.+?)\\s*$",
1168
+ "captures": {
1169
+ "1": {
1170
+ "name": "punctuation.definition.directive.restructuredtext"
1171
+ },
1172
+ "2": {
1173
+ "name": "support.directive.restructuredtext"
1174
+ },
1175
+ "3": {
1176
+ "name": "punctuation.separator.key-value.restructuredtext"
1177
+ },
1178
+ "4": {
1179
+ "name": "entity.name.directive.restructuredtext"
1180
+ }
1181
+ }
1182
+ }
1183
+ ]
1184
+ },
1185
+ "directive-options": {
1186
+ "patterns": [
1187
+ {
1188
+ "name": "meta.directive-option.restructuredtext",
1189
+ "match": "(:[^:]+:)\\s*(.*)",
1190
+ "captures": {
1191
+ "1": {
1192
+ "patterns": [
1193
+ {
1194
+ "include": "#tag-name"
1195
+ }
1196
+ ]
1197
+ },
1198
+ "2": {
1199
+ "name": "string.other.tag-value.restructuredtext"
1200
+ }
1201
+ }
1202
+ }
1203
+ ]
1204
+ },
1205
+ "image-options": {
1206
+ "patterns": [
1207
+ {
1208
+ "name": "meta.image-option.alt.restructuredtext",
1209
+ "match": "(:alt:)\\s*(.*)",
1210
+ "captures": {
1211
+ "1": {
1212
+ "patterns": [
1213
+ {
1214
+ "include": "#tag-name"
1215
+ }
1216
+ ]
1217
+ },
1218
+ "2": {
1219
+ "name": "string.other.tag-value.restructuredtext"
1220
+ }
1221
+ }
1222
+ },
1223
+ {
1224
+ "name": "meta.image-option.height.restructuredtext",
1225
+ "match": "(:height:)\\s*(.*)",
1226
+ "captures": {
1227
+ "1": {
1228
+ "patterns": [
1229
+ {
1230
+ "include": "#tag-name"
1231
+ }
1232
+ ]
1233
+ },
1234
+ "2": {
1235
+ "patterns": [
1236
+ {
1237
+ "include": "#length"
1238
+ }
1239
+ ]
1240
+ }
1241
+ }
1242
+ },
1243
+ {
1244
+ "name": "meta.image-option.width.restructuredtext",
1245
+ "match": "(:width:)\\s*(.*)",
1246
+ "captures": {
1247
+ "1": {
1248
+ "patterns": [
1249
+ {
1250
+ "include": "#tag-name"
1251
+ }
1252
+ ]
1253
+ },
1254
+ "2": {
1255
+ "patterns": [
1256
+ {
1257
+ "include": "#length"
1258
+ }
1259
+ ]
1260
+ }
1261
+ }
1262
+ },
1263
+ {
1264
+ "name": "meta.image-option.scale.restructuredtext",
1265
+ "match": "(:scale:)\\s*(.*)",
1266
+ "captures": {
1267
+ "1": {
1268
+ "patterns": [
1269
+ {
1270
+ "include": "#tag-name"
1271
+ }
1272
+ ]
1273
+ },
1274
+ "2": {
1275
+ "patterns": [
1276
+ {
1277
+ "include": "#length"
1278
+ }
1279
+ ]
1280
+ }
1281
+ }
1282
+ },
1283
+ {
1284
+ "name": "meta.image-option.align.restructuredtext",
1285
+ "match": "(:align:)\\s*(?:(top|middle|bottom|left|center|right)\\b)?",
1286
+ "captures": {
1287
+ "1": {
1288
+ "patterns": [
1289
+ {
1290
+ "include": "#tag-name"
1291
+ }
1292
+ ]
1293
+ },
1294
+ "2": {
1295
+ "name": "keyword.language.image-alignment.restructuredtext"
1296
+ }
1297
+ }
1298
+ },
1299
+ {
1300
+ "name": "meta.image-option.target.restructuredtext",
1301
+ "match": "(:target:)\\s*(.*)?",
1302
+ "captures": {
1303
+ "1": {
1304
+ "patterns": [
1305
+ {
1306
+ "include": "#tag-name"
1307
+ }
1308
+ ]
1309
+ },
1310
+ "2": {
1311
+ "name": "string.other.target.restructuredtext"
1312
+ }
1313
+ }
1314
+ },
1315
+ {
1316
+ "include": "#doctree-options"
1317
+ },
1318
+ {
1319
+ "include": "#directive-options"
1320
+ }
1321
+ ]
1322
+ },
1323
+ "doctree-options": {
1324
+ "patterns": [
1325
+ {
1326
+ "name": "meta.doctree-option.class.restructuredtext",
1327
+ "match": "(:class:)\\s*(.*)",
1328
+ "captures": {
1329
+ "1": {
1330
+ "patterns": [
1331
+ {
1332
+ "include": "#tag-name"
1333
+ }
1334
+ ]
1335
+ },
1336
+ "2": {
1337
+ "name": "string.other.class-list.restructuredtext"
1338
+ }
1339
+ }
1340
+ },
1341
+ {
1342
+ "name": "meta.doctree-option.name.restructuredtext",
1343
+ "match": "(:name:)\\s*(.*)",
1344
+ "captures": {
1345
+ "1": {
1346
+ "patterns": [
1347
+ {
1348
+ "include": "#tag-name"
1349
+ }
1350
+ ]
1351
+ },
1352
+ "2": {
1353
+ "name": "string.other.name.restructuredtext"
1354
+ }
1355
+ }
1356
+ }
1357
+ ]
1358
+ },
1359
+ "domains": {
1360
+ "patterns": [
1361
+ {
1362
+ "name": "meta.sphinx-domain.restructuredtext",
1363
+ "contentName": "source.embedded.python",
1364
+ "patterns": [
1365
+ {
1366
+ "include": "source.python"
1367
+ }
1368
+ ],
1369
+ "begin": "^(\\s*)(\\.\\.)\\s+(py)(:)([^:]+)(::)",
1370
+ "end": "^(?!\\s*$|\\1[ \\t]{5,}\\S)",
1371
+ "beginCaptures": {
1372
+ "2": {
1373
+ "name": "punctuation.definition.directive.restructuredtext"
1374
+ },
1375
+ "3": {
1376
+ "name": "support.directive.restructuredtext"
1377
+ },
1378
+ "4": {
1379
+ "name": "punctuation.separator.key-value.restructuredtext"
1380
+ },
1381
+ "5": {
1382
+ "name": "support.directive.restructuredtext"
1383
+ },
1384
+ "6": {
1385
+ "name": "punctuation.separator.key-value.restructuredtext"
1386
+ }
1387
+ }
1388
+ },
1389
+ {
1390
+ "name": "meta.sphinx-domain.restructuredtext",
1391
+ "contentName": "source.embedded.c",
1392
+ "patterns": [
1393
+ {
1394
+ "include": "source.c"
1395
+ }
1396
+ ],
1397
+ "begin": "^(\\s*)(\\.\\.)\\s+(c)(:)([^:]+)(::)",
1398
+ "end": "^(?!\\s*$|\\1[ \\t]{5,}\\S)",
1399
+ "beginCaptures": {
1400
+ "2": {
1401
+ "name": "punctuation.definition.directive.restructuredtext"
1402
+ },
1403
+ "3": {
1404
+ "name": "support.directive.restructuredtext"
1405
+ },
1406
+ "4": {
1407
+ "name": "punctuation.separator.key-value.restructuredtext"
1408
+ },
1409
+ "5": {
1410
+ "name": "support.directive.restructuredtext"
1411
+ },
1412
+ "6": {
1413
+ "name": "punctuation.separator.key-value.restructuredtext"
1414
+ }
1415
+ }
1416
+ },
1417
+ {
1418
+ "name": "meta.sphinx-domain.restructuredtext",
1419
+ "begin": "^(\\s*)(\\.\\.)\\s+(cpp)(::?)([^:]+)(::)",
1420
+ "end": "^(?!\\s*$|\\1[ \\t]{5,}\\S)",
1421
+ "beginCaptures": {
1422
+ "2": {
1423
+ "name": "punctuation.definition.directive.restructuredtext"
1424
+ },
1425
+ "3": {
1426
+ "name": "support.directive.restructuredtext"
1427
+ },
1428
+ "4": {
1429
+ "name": "punctuation.separator.key-value.restructuredtext"
1430
+ },
1431
+ "5": {
1432
+ "name": "support.directive.restructuredtext"
1433
+ },
1434
+ "6": {
1435
+ "name": "punctuation.separator.key-value.restructuredtext"
1436
+ }
1437
+ },
1438
+ "patterns": [
1439
+ {
1440
+ "match": "(.+)(\\\\?)$",
1441
+ "captures": {
1442
+ "1": {
1443
+ "name": "source.embedded.cpp",
1444
+ "patterns": [
1445
+ {
1446
+ "include": "source.cpp"
1447
+ }
1448
+ ]
1449
+ },
1450
+ "2": {
1451
+ "name": "constant.character.escape.newline.restructuredtext"
1452
+ }
1453
+ }
1454
+ }
1455
+ ]
1456
+ },
1457
+ {
1458
+ "name": "meta.sphinx-domain.restructuredtext",
1459
+ "begin": "^(\\s*)(\\.\\.)\\s+(js)(:)([^:]+)(::)",
1460
+ "end": "^(?!\\s*$|\\1[ \\t]{5,}\\S)",
1461
+ "beginCaptures": {
1462
+ "2": {
1463
+ "name": "punctuation.definition.directive.restructuredtext"
1464
+ },
1465
+ "3": {
1466
+ "name": "support.directive.restructuredtext"
1467
+ },
1468
+ "4": {
1469
+ "name": "punctuation.separator.key-value.restructuredtext"
1470
+ },
1471
+ "5": {
1472
+ "name": "support.directive.restructuredtext"
1473
+ },
1474
+ "6": {
1475
+ "name": "punctuation.separator.key-value.restructuredtext"
1476
+ }
1477
+ },
1478
+ "patterns": [
1479
+ {
1480
+ "match": "(.+)(\\\\?)$",
1481
+ "captures": {
1482
+ "1": {
1483
+ "name": "source.embedded.js",
1484
+ "patterns": [
1485
+ {
1486
+ "include": "source.js"
1487
+ }
1488
+ ]
1489
+ },
1490
+ "2": {
1491
+ "name": "constant.character.escape.newline.restructuredtext"
1492
+ }
1493
+ }
1494
+ }
1495
+ ]
1496
+ },
1497
+ {
1498
+ "name": "meta.sphinx-domain.restructuredtext",
1499
+ "contentName": "string.unquoted.domain.restructuredtext",
1500
+ "begin": "^(\\s*)(\\.\\.)\\s+([^:]+)(::?)([^:]+)(::)",
1501
+ "end": "^(?!\\s*$|\\1[ \\t]{5,}\\S)",
1502
+ "beginCaptures": {
1503
+ "2": {
1504
+ "name": "punctuation.definition.directive.restructuredtext"
1505
+ },
1506
+ "3": {
1507
+ "name": "support.directive.restructuredtext"
1508
+ },
1509
+ "4": {
1510
+ "name": "punctuation.separator.key-value.restructuredtext"
1511
+ },
1512
+ "5": {
1513
+ "name": "support.directive.restructuredtext"
1514
+ },
1515
+ "6": {
1516
+ "name": "punctuation.separator.key-value.restructuredtext"
1517
+ }
1518
+ }
1519
+ }
1520
+ ]
1521
+ }
1522
+ }
561
1523
  }