github-linguist-grammars 4.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (335) hide show
  1. checksums.yaml +7 -0
  2. data/grammars/file.lasso.json +713 -0
  3. data/grammars/module.ceylon.json +54 -0
  4. data/grammars/objdump.x86asm.json +73 -0
  5. data/grammars/source.Inform7.json +45 -0
  6. data/grammars/source.Kotlin.json +774 -0
  7. data/grammars/source.LS.json +104 -0
  8. data/grammars/source.MCPOST.json +68 -0
  9. data/grammars/source.MOD.json +70 -0
  10. data/grammars/source.abap.json +176 -0
  11. data/grammars/source.abl.json +138 -0
  12. data/grammars/source.actionscript.3.json +1571 -0
  13. data/grammars/source.acucobol.json +16 -0
  14. data/grammars/source.ada.json +140 -0
  15. data/grammars/source.agda.json +254 -0
  16. data/grammars/source.ahk.json +171 -0
  17. data/grammars/source.alloy.json +44 -0
  18. data/grammars/source.ampl.json +157 -0
  19. data/grammars/source.antlr.json +300 -0
  20. data/grammars/source.apache-config.json +352 -0
  21. data/grammars/source.apache-config.mod_perl.json +70 -0
  22. data/grammars/source.apl.json +442 -0
  23. data/grammars/source.applescript.json +1385 -0
  24. data/grammars/source.apt.json +25 -0
  25. data/grammars/source.asm.x86.json +182 -0
  26. data/grammars/source.asp.json +157 -0
  27. data/grammars/source.aspectj.json +963 -0
  28. data/grammars/source.ats.json +170 -0
  29. data/grammars/source.autoit.3.json +132 -0
  30. data/grammars/source.awk.json +388 -0
  31. data/grammars/source.befunge.json +38 -0
  32. data/grammars/source.bf.json +36 -0
  33. data/grammars/source.bison.json +59 -0
  34. data/grammars/source.blitzmax.json +912 -0
  35. data/grammars/source.boo.json +452 -0
  36. data/grammars/source.brightauthorproject.json +29 -0
  37. data/grammars/source.brightscript.json +158 -0
  38. data/grammars/source.bro.json +409 -0
  39. data/grammars/source.bsv.json +283 -0
  40. data/grammars/source.c++.json +364 -0
  41. data/grammars/source.c++.qt.json +37 -0
  42. data/grammars/source.c.ec.json +39 -0
  43. data/grammars/source.c.json +727 -0
  44. data/grammars/source.c.platform.json +154 -0
  45. data/grammars/source.cache.cmake.json +75 -0
  46. data/grammars/source.cake.json +16 -0
  47. data/grammars/source.camlp4.ocaml.json +63 -0
  48. data/grammars/source.capnp.json +93 -0
  49. data/grammars/source.ceylon.json +77 -0
  50. data/grammars/source.cfscript.cfc.json +170 -0
  51. data/grammars/source.cfscript.json +744 -0
  52. data/grammars/source.chapel.json +240 -0
  53. data/grammars/source.cirru.json +66 -0
  54. data/grammars/source.clarion.json +159 -0
  55. data/grammars/source.clips.json +80 -0
  56. data/grammars/source.clojure.json +397 -0
  57. data/grammars/source.cm.json +54 -0
  58. data/grammars/source.cmake.json +181 -0
  59. data/grammars/source.cobol.json +528 -0
  60. data/grammars/source.coffee.json +678 -0
  61. data/grammars/source.compiled-papyrus.json +11 -0
  62. data/grammars/source.cool.json +103 -0
  63. data/grammars/source.coq.json +62 -0
  64. data/grammars/source.crystal.json +2760 -0
  65. data/grammars/source.cs.json +556 -0
  66. data/grammars/source.css.json +630 -0
  67. data/grammars/source.css.less.json +276 -0
  68. data/grammars/source.css.mss.json +256 -0
  69. data/grammars/source.csx.json +16 -0
  70. data/grammars/source.cuda-c++.json +137 -0
  71. data/grammars/source.cython.json +2108 -0
  72. data/grammars/source.d.json +722 -0
  73. data/grammars/source.dart.json +763 -0
  74. data/grammars/source.desktop.json +90 -0
  75. data/grammars/source.diff.json +162 -0
  76. data/grammars/source.dockerfile.json +89 -0
  77. data/grammars/source.dosbatch.json +70 -0
  78. data/grammars/source.dot.json +126 -0
  79. data/grammars/source.dylan.json +217 -0
  80. data/grammars/source.eiffel.json +138 -0
  81. data/grammars/source.elixir.json +737 -0
  82. data/grammars/source.elm.json +355 -0
  83. data/grammars/source.erazor.json +126 -0
  84. data/grammars/source.erlang.json +1674 -0
  85. data/grammars/source.essl.json +50 -0
  86. data/grammars/source.factor.json +260 -0
  87. data/grammars/source.fan.json +188 -0
  88. data/grammars/source.fancy.json +270 -0
  89. data/grammars/source.fish.json +214 -0
  90. data/grammars/source.forth.json +101 -0
  91. data/grammars/source.fortran.json +499 -0
  92. data/grammars/source.fortran.modern.json +226 -0
  93. data/grammars/source.fsharp.json +403 -0
  94. data/grammars/source.gap.json +167 -0
  95. data/grammars/source.gcode.json +25 -0
  96. data/grammars/source.gdscript.json +154 -0
  97. data/grammars/source.gfm.json +1270 -0
  98. data/grammars/source.glsl.json +71 -0
  99. data/grammars/source.gnuplot.json +276 -0
  100. data/grammars/source.go.json +552 -0
  101. data/grammars/source.golo.json +182 -0
  102. data/grammars/source.gosu.2.json +163 -0
  103. data/grammars/source.grace.json +679 -0
  104. data/grammars/source.groovy.gradle.json +73 -0
  105. data/grammars/source.groovy.json +1385 -0
  106. data/grammars/source.harbour.json +450 -0
  107. data/grammars/source.haskell.json +449 -0
  108. data/grammars/source.haxe.2.json +1243 -0
  109. data/grammars/source.hss.1.json +464 -0
  110. data/grammars/source.httpspec.json +287 -0
  111. data/grammars/source.hxml.json +26 -0
  112. data/grammars/source.hy.json +270 -0
  113. data/grammars/source.idl-dlm.json +112 -0
  114. data/grammars/source.idl.json +267 -0
  115. data/grammars/source.idris.json +537 -0
  116. data/grammars/source.ini.json +113 -0
  117. data/grammars/source.inno.json +65 -0
  118. data/grammars/source.io.json +164 -0
  119. data/grammars/source.ioke.json +272 -0
  120. data/grammars/source.isabelle.root.json +68 -0
  121. data/grammars/source.isabelle.theory.json +106 -0
  122. data/grammars/source.j.json +49 -0
  123. data/grammars/source.jade.json +1009 -0
  124. data/grammars/source.jasmin.json +299 -0
  125. data/grammars/source.java-properties.json +97 -0
  126. data/grammars/source.java.json +1026 -0
  127. data/grammars/source.jcl.json +49 -0
  128. data/grammars/source.jflex.json +490 -0
  129. data/grammars/source.jq.json +218 -0
  130. data/grammars/source.js.json +948 -0
  131. data/grammars/source.js.jsx.json +2937 -0
  132. data/grammars/source.js.objj.json +424 -0
  133. data/grammars/source.js.regexp.json +150 -0
  134. data/grammars/source.js.regexp.replacement.json +30 -0
  135. data/grammars/source.json.json +149 -0
  136. data/grammars/source.julia.json +407 -0
  137. data/grammars/source.lean.json +145 -0
  138. data/grammars/source.lid.json +23 -0
  139. data/grammars/source.lilypond.json +623 -0
  140. data/grammars/source.lisp.json +111 -0
  141. data/grammars/source.litcoffee.json +669 -0
  142. data/grammars/source.livescript.json +616 -0
  143. data/grammars/source.llvm.json +71 -0
  144. data/grammars/source.logos.json +31 -0
  145. data/grammars/source.logtalk.json +315 -0
  146. data/grammars/source.loomscript.json +214 -0
  147. data/grammars/source.lsl.json +216 -0
  148. data/grammars/source.lua.json +191 -0
  149. data/grammars/source.makefile.json +474 -0
  150. data/grammars/source.makegen.json +13 -0
  151. data/grammars/source.man.json +53 -0
  152. data/grammars/source.mask.json +701 -0
  153. data/grammars/source.mata.json +133 -0
  154. data/grammars/source.mathematica.json +429 -0
  155. data/grammars/source.matlab.json +776 -0
  156. data/grammars/source.mercury.json +251 -0
  157. data/grammars/source.ml.json +291 -0
  158. data/grammars/source.modelica.json +142 -0
  159. data/grammars/source.modula2.json +103 -0
  160. data/grammars/source.monkey.json +701 -0
  161. data/grammars/source.moonscript.json +149 -0
  162. data/grammars/source.mupad.json +149 -0
  163. data/grammars/source.nant-build.json +86 -0
  164. data/grammars/source.ncl.json +66 -0
  165. data/grammars/source.nemerle.json +137 -0
  166. data/grammars/source.nesc.json +27 -0
  167. data/grammars/source.netlinx.erb.json +47 -0
  168. data/grammars/source.netlinx.json +768 -0
  169. data/grammars/source.nginx.json +797 -0
  170. data/grammars/source.nim.json +1150 -0
  171. data/grammars/source.nim_filter.json +133 -0
  172. data/grammars/source.nimcfg.json +116 -0
  173. data/grammars/source.ninja.json +66 -0
  174. data/grammars/source.nit.json +238 -0
  175. data/grammars/source.nix.json +1200 -0
  176. data/grammars/source.nmml.json +87 -0
  177. data/grammars/source.nsis.json +150 -0
  178. data/grammars/source.objc++.json +19 -0
  179. data/grammars/source.objc.json +918 -0
  180. data/grammars/source.objc.platform.json +277 -0
  181. data/grammars/source.ocaml.json +1426 -0
  182. data/grammars/source.ocamllex.json +305 -0
  183. data/grammars/source.ocamlyacc.json +346 -0
  184. data/grammars/source.octave.json +451 -0
  185. data/grammars/source.ooc.json +692 -0
  186. data/grammars/source.opa.json +206 -0
  187. data/grammars/source.opal.json +415 -0
  188. data/grammars/source.opalsysdefs.json +70 -0
  189. data/grammars/source.opencobol.json +65 -0
  190. data/grammars/source.ox.json +97 -0
  191. data/grammars/source.oz.json +84 -0
  192. data/grammars/source.papyrus-assembly.json +266 -0
  193. data/grammars/source.papyrus.json +231 -0
  194. data/grammars/source.parrot.pir.json +117 -0
  195. data/grammars/source.pascal.json +150 -0
  196. data/grammars/source.perl.6.json +310 -0
  197. data/grammars/source.perl.json +2413 -0
  198. data/grammars/source.php.zephir.json +362 -0
  199. data/grammars/source.pig_latin.json +172 -0
  200. data/grammars/source.pike.json +62 -0
  201. data/grammars/source.plsql.oracle.json +642 -0
  202. data/grammars/source.po.json +232 -0
  203. data/grammars/source.pogoscript.json +85 -0
  204. data/grammars/source.postscript.json +231 -0
  205. data/grammars/source.powershell.json +755 -0
  206. data/grammars/source.processing.json +885 -0
  207. data/grammars/source.prolog.eclipse.json +206 -0
  208. data/grammars/source.prolog.json +292 -0
  209. data/grammars/source.protobuf.json +395 -0
  210. data/grammars/source.pubspec.json +13 -0
  211. data/grammars/source.puppet.json +494 -0
  212. data/grammars/source.purescript.json +818 -0
  213. data/grammars/source.pyjade.json +1010 -0
  214. data/grammars/source.python.django.json +34 -0
  215. data/grammars/source.python.json +1960 -0
  216. data/grammars/source.python.salt.json +13 -0
  217. data/grammars/source.qmake.json +217 -0
  218. data/grammars/source.qml.json +195 -0
  219. data/grammars/source.r.json +203 -0
  220. data/grammars/source.racket.json +119 -0
  221. data/grammars/source.rebol.json +647 -0
  222. data/grammars/source.red.json +652 -0
  223. data/grammars/source.regexp.babel.json +190 -0
  224. data/grammars/source.regexp.python.json +187 -0
  225. data/grammars/source.regexp.spin.json +188 -0
  226. data/grammars/source.ruby.json +1956 -0
  227. data/grammars/source.ruby.rspec.cucumber.steps.json +274 -0
  228. data/grammars/source.rust.json +269 -0
  229. data/grammars/source.sas.json +322 -0
  230. data/grammars/source.sas_log.json +26 -0
  231. data/grammars/source.sass.json +248 -0
  232. data/grammars/source.sbt.json +36 -0
  233. data/grammars/source.scad.json +152 -0
  234. data/grammars/source.scala.json +739 -0
  235. data/grammars/source.scaml.json +466 -0
  236. data/grammars/source.scheme.json +370 -0
  237. data/grammars/source.scilab.json +103 -0
  238. data/grammars/source.scss.json +1321 -0
  239. data/grammars/source.shell.json +1212 -0
  240. data/grammars/source.smali.json +1668 -0
  241. data/grammars/source.smalltalk.json +135 -0
  242. data/grammars/source.smt.json +173 -0
  243. data/grammars/source.sp.json +118 -0
  244. data/grammars/source.sparql.json +23 -0
  245. data/grammars/source.spin.json +936 -0
  246. data/grammars/source.sqf.json +112 -0
  247. data/grammars/source.sql.json +473 -0
  248. data/grammars/source.stata.json +208 -0
  249. data/grammars/source.strings.json +53 -0
  250. data/grammars/source.stylus.json +1021 -0
  251. data/grammars/source.swift.json +965 -0
  252. data/grammars/source.systemverilog.json +1050 -0
  253. data/grammars/source.tcl.json +277 -0
  254. data/grammars/source.tea.json +180 -0
  255. data/grammars/source.thrift.json +704 -0
  256. data/grammars/source.toml.json +327 -0
  257. data/grammars/source.ts.json +1094 -0
  258. data/grammars/source.tsx.json +1324 -0
  259. data/grammars/source.turtle.json +505 -0
  260. data/grammars/source.txl.json +62 -0
  261. data/grammars/source.ucfconstraints.json +72 -0
  262. data/grammars/source.vala.json +814 -0
  263. data/grammars/source.varnish.vcl.json +343 -0
  264. data/grammars/source.vbnet.json +338 -0
  265. data/grammars/source.verilog.json +302 -0
  266. data/grammars/source.vhdl.json +1349 -0
  267. data/grammars/source.viml.json +224 -0
  268. data/grammars/source.webidl.json +814 -0
  269. data/grammars/source.x10.json +68 -0
  270. data/grammars/source.x86asm.json +47 -0
  271. data/grammars/source.xc.json +379 -0
  272. data/grammars/source.xq.json +241 -0
  273. data/grammars/source.xquery.json +193 -0
  274. data/grammars/source.xtend.json +733 -0
  275. data/grammars/source.yaml.json +334 -0
  276. data/grammars/source.yaml.salt.json +348 -0
  277. data/grammars/text.bibtex.json +251 -0
  278. data/grammars/text.cfml.basic.json +736 -0
  279. data/grammars/text.dart-analysis-output.json +162 -0
  280. data/grammars/text.dart-doccomments.json +19 -0
  281. data/grammars/text.elixir.json +45 -0
  282. data/grammars/text.gherkin.feature.json +135 -0
  283. data/grammars/text.groff.json +113 -0
  284. data/grammars/text.haml.json +299 -0
  285. data/grammars/text.html.abl.json +24 -0
  286. data/grammars/text.html.asciidoc.json +492 -0
  287. data/grammars/text.html.asdoc.json +541 -0
  288. data/grammars/text.html.asp.json +58 -0
  289. data/grammars/text.html.basic.json +552 -0
  290. data/grammars/text.html.cfm.json +811 -0
  291. data/grammars/text.html.creole.json +329 -0
  292. data/grammars/text.html.django.json +69 -0
  293. data/grammars/text.html.elixir.json +18 -0
  294. data/grammars/text.html.erb.json +157 -0
  295. data/grammars/text.html.erlang.yaws.json +72 -0
  296. data/grammars/text.html.factor.json +27 -0
  297. data/grammars/text.html.handlebars.json +783 -0
  298. data/grammars/text.html.jsp.json +1203 -0
  299. data/grammars/text.html.liquid.json +35 -0
  300. data/grammars/text.html.mako.json +729 -0
  301. data/grammars/text.html.markdown.source.gfm.apib.json +1297 -0
  302. data/grammars/text.html.markdown.source.gfm.mson.json +1165 -0
  303. data/grammars/text.html.mediawiki.json +972 -0
  304. data/grammars/text.html.php.json +2607 -0
  305. data/grammars/text.html.slash.json +313 -0
  306. data/grammars/text.html.smarty.json +216 -0
  307. data/grammars/text.html.ssp.json +49 -0
  308. data/grammars/text.html.tcl.json +44 -0
  309. data/grammars/text.html.twig.json +1353 -0
  310. data/grammars/text.html.vue.json +642 -0
  311. data/grammars/text.idl-idldoc.json +14 -0
  312. data/grammars/text.junit-test-report.json +92 -0
  313. data/grammars/text.log.latex.json +86 -0
  314. data/grammars/text.python.console.json +25 -0
  315. data/grammars/text.python.traceback.json +46 -0
  316. data/grammars/text.rdoc.json +48 -0
  317. data/grammars/text.restructuredtext.json +561 -0
  318. data/grammars/text.robot.json +73 -0
  319. data/grammars/text.shell-session.json +48 -0
  320. data/grammars/text.slim.json +527 -0
  321. data/grammars/text.tex.json +271 -0
  322. data/grammars/text.tex.latex.beamer.json +63 -0
  323. data/grammars/text.tex.latex.haskell.json +56 -0
  324. data/grammars/text.tex.latex.json +1013 -0
  325. data/grammars/text.tex.latex.memoir.json +99 -0
  326. data/grammars/text.tex.latex.rd.json +117 -0
  327. data/grammars/text.xml.ant.json +202 -0
  328. data/grammars/text.xml.flex-config.json +2634 -0
  329. data/grammars/text.xml.genshi.json +34 -0
  330. data/grammars/text.xml.json +364 -0
  331. data/grammars/text.xml.pom.json +774 -0
  332. data/grammars/text.xml.xsl.json +94 -0
  333. data/grammars/text.zone_file.json +72 -0
  334. data/lib/linguist/grammars.rb +13 -0
  335. metadata +389 -0
@@ -0,0 +1,1212 @@
1
+ {
2
+ "fileTypes": [
3
+ "sh",
4
+ "bash",
5
+ "ksh",
6
+ "zsh",
7
+ "zshenv",
8
+ "zshrc",
9
+ "bashrc",
10
+ "bash_profile",
11
+ "bash_login",
12
+ "profile",
13
+ "bash_logout",
14
+ ".textmate_init",
15
+ "npmrc",
16
+ "PKGBUILD",
17
+ "cygport"
18
+ ],
19
+ "firstLineMatch": "^#!.*\\b(bash|zsh|sh|tcsh|ksh|dash|ash|csh)|^#\\s*-\\*-[^*]*mode:\\s*shell-script[^*]*-\\*-",
20
+ "name": "Shell Script",
21
+ "patterns": [
22
+ {
23
+ "include": "#comment"
24
+ },
25
+ {
26
+ "include": "#pipeline"
27
+ },
28
+ {
29
+ "include": "#list"
30
+ },
31
+ {
32
+ "include": "#compound-command"
33
+ },
34
+ {
35
+ "include": "#loop"
36
+ },
37
+ {
38
+ "include": "#function-definition"
39
+ },
40
+ {
41
+ "include": "#string"
42
+ },
43
+ {
44
+ "include": "#variable"
45
+ },
46
+ {
47
+ "include": "#interpolation"
48
+ },
49
+ {
50
+ "include": "#heredoc"
51
+ },
52
+ {
53
+ "include": "#herestring"
54
+ },
55
+ {
56
+ "include": "#redirection"
57
+ },
58
+ {
59
+ "include": "#pathname"
60
+ },
61
+ {
62
+ "include": "#keyword"
63
+ },
64
+ {
65
+ "include": "#support"
66
+ }
67
+ ],
68
+ "repository": {
69
+ "case-clause": {
70
+ "patterns": [
71
+ {
72
+ "begin": "(?=\\S)",
73
+ "end": ";;",
74
+ "endCaptures": {
75
+ "0": {
76
+ "name": "punctuation.terminator.case-clause.shell"
77
+ }
78
+ },
79
+ "name": "meta.scope.case-clause.shell",
80
+ "patterns": [
81
+ {
82
+ "begin": "(\\(|(?=\\S))",
83
+ "captures": {
84
+ "0": {
85
+ "name": "punctuation.definition.case-pattern.shell"
86
+ }
87
+ },
88
+ "end": "\\)",
89
+ "name": "meta.scope.case-pattern.shell",
90
+ "patterns": [
91
+ {
92
+ "match": "\\|",
93
+ "name": "punctuation.separator.pipe-sign.shell"
94
+ },
95
+ {
96
+ "include": "#string"
97
+ },
98
+ {
99
+ "include": "#variable"
100
+ },
101
+ {
102
+ "include": "#interpolation"
103
+ },
104
+ {
105
+ "include": "#pathname"
106
+ }
107
+ ]
108
+ },
109
+ {
110
+ "begin": "(?<=\\))",
111
+ "end": "(?=;;)",
112
+ "name": "meta.scope.case-clause-body.shell",
113
+ "patterns": [
114
+ {
115
+ "include": "$self"
116
+ }
117
+ ]
118
+ }
119
+ ]
120
+ }
121
+ ]
122
+ },
123
+ "comment": {
124
+ "begin": "(^[ \\t]+)?(?<!\\S)(?=#)(?!#\\{)",
125
+ "beginCaptures": {
126
+ "1": {
127
+ "name": "punctuation.whitespace.comment.leading.shell"
128
+ }
129
+ },
130
+ "end": "(?!\\G)",
131
+ "patterns": [
132
+ {
133
+ "begin": "#",
134
+ "beginCaptures": {
135
+ "0": {
136
+ "name": "punctuation.definition.comment.shell"
137
+ }
138
+ },
139
+ "end": "\\n",
140
+ "name": "comment.line.number-sign.shell"
141
+ }
142
+ ]
143
+ },
144
+ "compound-command": {
145
+ "patterns": [
146
+ {
147
+ "begin": "(\\[{2})",
148
+ "captures": {
149
+ "1": {
150
+ "name": "punctuation.definition.logical-expression.shell"
151
+ }
152
+ },
153
+ "end": "(\\]{2})",
154
+ "name": "meta.scope.logical-expression.shell",
155
+ "patterns": [
156
+ {
157
+ "include": "#logical-expression"
158
+ },
159
+ {
160
+ "include": "$self"
161
+ }
162
+ ]
163
+ },
164
+ {
165
+ "begin": "(\\({2})",
166
+ "beginCaptures": {
167
+ "0": {
168
+ "name": "punctuation.definition.string.begin.shell"
169
+ }
170
+ },
171
+ "end": "(\\){2})",
172
+ "endCaptures": {
173
+ "0": {
174
+ "name": "punctuation.definition.string.end.shell"
175
+ }
176
+ },
177
+ "name": "string.other.math.shell",
178
+ "patterns": [
179
+ {
180
+ "include": "#math"
181
+ }
182
+ ]
183
+ },
184
+ {
185
+ "begin": "(\\()",
186
+ "captures": {
187
+ "1": {
188
+ "name": "punctuation.definition.subshell.shell"
189
+ }
190
+ },
191
+ "end": "(\\))",
192
+ "name": "meta.scope.subshell.shell",
193
+ "patterns": [
194
+ {
195
+ "include": "$self"
196
+ }
197
+ ]
198
+ },
199
+ {
200
+ "begin": "(?<=\\s|^)(\\{)(?=\\s|$)",
201
+ "captures": {
202
+ "1": {
203
+ "name": "punctuation.definition.group.shell"
204
+ }
205
+ },
206
+ "end": "(?<=^|;)\\s*(\\})",
207
+ "name": "meta.scope.group.shell",
208
+ "patterns": [
209
+ {
210
+ "include": "$self"
211
+ }
212
+ ]
213
+ }
214
+ ]
215
+ },
216
+ "function-definition": {
217
+ "patterns": [
218
+ {
219
+ "begin": "\\b(function)\\s+([^\\s\\\\]+)(?:\\s*(\\(\\)))?",
220
+ "beginCaptures": {
221
+ "1": {
222
+ "name": "storage.type.function.shell"
223
+ },
224
+ "2": {
225
+ "name": "entity.name.function.shell"
226
+ },
227
+ "3": {
228
+ "name": "punctuation.definition.arguments.shell"
229
+ }
230
+ },
231
+ "end": ";|&|$",
232
+ "endCaptures": {
233
+ "0": {
234
+ "name": "punctuation.definition.function.shell"
235
+ }
236
+ },
237
+ "name": "meta.function.shell",
238
+ "patterns": [
239
+ {
240
+ "include": "$self"
241
+ }
242
+ ]
243
+ },
244
+ {
245
+ "begin": "\\b([^\\s\\\\=]+)\\s*(\\(\\))",
246
+ "beginCaptures": {
247
+ "1": {
248
+ "name": "entity.name.function.shell"
249
+ },
250
+ "2": {
251
+ "name": "punctuation.definition.arguments.shell"
252
+ }
253
+ },
254
+ "end": ";|&|$",
255
+ "endCaptures": {
256
+ "0": {
257
+ "name": "punctuation.definition.function.shell"
258
+ }
259
+ },
260
+ "name": "meta.function.shell",
261
+ "patterns": [
262
+ {
263
+ "include": "$self"
264
+ }
265
+ ]
266
+ }
267
+ ]
268
+ },
269
+ "heredoc": {
270
+ "patterns": [
271
+ {
272
+ "begin": "(<<)-(\"|'|)(RUBY)\\2",
273
+ "beginCaptures": {
274
+ "1": {
275
+ "name": "keyword.operator.heredoc.shell"
276
+ },
277
+ "3": {
278
+ "name": "keyword.control.heredoc-token.shell"
279
+ }
280
+ },
281
+ "captures": {
282
+ "0": {
283
+ "name": "punctuation.definition.string.shell"
284
+ }
285
+ },
286
+ "contentName": "source.ruby.embedded.shell",
287
+ "end": "^\\t*(RUBY)\\b",
288
+ "endCaptures": {
289
+ "1": {
290
+ "name": "keyword.control.heredoc-token.shell"
291
+ }
292
+ },
293
+ "name": "string.unquoted.heredoc.no-indent.ruby.shell",
294
+ "patterns": [
295
+ {
296
+ "include": "source.ruby"
297
+ }
298
+ ]
299
+ },
300
+ {
301
+ "begin": "(<<)(\"|'|)(RUBY)\\2",
302
+ "beginCaptures": {
303
+ "1": {
304
+ "name": "keyword.operator.heredoc.shell"
305
+ },
306
+ "3": {
307
+ "name": "keyword.control.heredoc-token.shell"
308
+ }
309
+ },
310
+ "captures": {
311
+ "0": {
312
+ "name": "punctuation.definition.string.shell"
313
+ }
314
+ },
315
+ "contentName": "source.ruby.embedded.shell",
316
+ "end": "^(RUBY)\\b",
317
+ "endCaptures": {
318
+ "1": {
319
+ "name": "keyword.control.heredoc-token.shell"
320
+ }
321
+ },
322
+ "name": "string.unquoted.heredoc.ruby.shell",
323
+ "patterns": [
324
+ {
325
+ "include": "source.ruby"
326
+ }
327
+ ]
328
+ },
329
+ {
330
+ "begin": "(<<)-(\"|'|)(PYTHON)\\2",
331
+ "beginCaptures": {
332
+ "1": {
333
+ "name": "keyword.operator.heredoc.shell"
334
+ },
335
+ "3": {
336
+ "name": "keyword.control.heredoc-token.shell"
337
+ }
338
+ },
339
+ "captures": {
340
+ "0": {
341
+ "name": "punctuation.definition.string.shell"
342
+ }
343
+ },
344
+ "contentName": "source.python.embedded.shell",
345
+ "end": "^\\t*(PYTHON)\\b",
346
+ "endCaptures": {
347
+ "1": {
348
+ "name": "keyword.control.heredoc-token.shell"
349
+ }
350
+ },
351
+ "name": "string.unquoted.heredoc.no-indent.python.shell",
352
+ "patterns": [
353
+ {
354
+ "include": "source.python"
355
+ }
356
+ ]
357
+ },
358
+ {
359
+ "begin": "(<<)(\"|'|)(PYTHON)\\2",
360
+ "beginCaptures": {
361
+ "1": {
362
+ "name": "keyword.operator.heredoc.shell"
363
+ },
364
+ "3": {
365
+ "name": "keyword.control.heredoc-token.shell"
366
+ }
367
+ },
368
+ "captures": {
369
+ "0": {
370
+ "name": "punctuation.definition.string.shell"
371
+ }
372
+ },
373
+ "contentName": "source.python.embedded.shell",
374
+ "end": "^(PYTHON)\\b",
375
+ "endCaptures": {
376
+ "1": {
377
+ "name": "keyword.control.heredoc-token.shell"
378
+ }
379
+ },
380
+ "name": "string.unquoted.heredoc.python.shell",
381
+ "patterns": [
382
+ {
383
+ "include": "source.python"
384
+ }
385
+ ]
386
+ },
387
+ {
388
+ "begin": "(<<)-(\"|'|)(APPLESCRIPT)\\2",
389
+ "beginCaptures": {
390
+ "1": {
391
+ "name": "keyword.operator.heredoc.shell"
392
+ },
393
+ "3": {
394
+ "name": "keyword.control.heredoc-token.shell"
395
+ }
396
+ },
397
+ "captures": {
398
+ "0": {
399
+ "name": "punctuation.definition.string.shell"
400
+ }
401
+ },
402
+ "contentName": "source.applescript.embedded.shell",
403
+ "end": "^\\t*(APPLESCRIPT)\\b",
404
+ "endCaptures": {
405
+ "1": {
406
+ "name": "keyword.control.heredoc-token.shell"
407
+ }
408
+ },
409
+ "name": "string.unquoted.heredoc.no-indent.applescript.shell",
410
+ "patterns": [
411
+ {
412
+ "include": "source.applescript"
413
+ }
414
+ ]
415
+ },
416
+ {
417
+ "begin": "(<<)(\"|'|)(APPLESCRIPT)\\2",
418
+ "beginCaptures": {
419
+ "1": {
420
+ "name": "keyword.operator.heredoc.shell"
421
+ },
422
+ "3": {
423
+ "name": "keyword.control.heredoc-token.shell"
424
+ }
425
+ },
426
+ "captures": {
427
+ "0": {
428
+ "name": "punctuation.definition.string.shell"
429
+ }
430
+ },
431
+ "contentName": "source.applescript.embedded.shell",
432
+ "end": "^(APPLESCRIPT)\\b",
433
+ "endCaptures": {
434
+ "1": {
435
+ "name": "keyword.control.heredoc-token.shell"
436
+ }
437
+ },
438
+ "name": "string.unquoted.heredoc.applescript.shell",
439
+ "patterns": [
440
+ {
441
+ "include": "source.applescript"
442
+ }
443
+ ]
444
+ },
445
+ {
446
+ "begin": "(<<)-(\"|'|)(HTML)\\2",
447
+ "beginCaptures": {
448
+ "1": {
449
+ "name": "keyword.operator.heredoc.shell"
450
+ },
451
+ "3": {
452
+ "name": "keyword.control.heredoc-token.shell"
453
+ }
454
+ },
455
+ "captures": {
456
+ "0": {
457
+ "name": "punctuation.definition.string.shell"
458
+ }
459
+ },
460
+ "contentName": "text.html.embedded.shell",
461
+ "end": "^\\t*(HTML)\\b",
462
+ "endCaptures": {
463
+ "1": {
464
+ "name": "keyword.control.heredoc-token.shell"
465
+ }
466
+ },
467
+ "name": "string.unquoted.heredoc.no-indent.html.shell",
468
+ "patterns": [
469
+ {
470
+ "include": "text.html.basic"
471
+ }
472
+ ]
473
+ },
474
+ {
475
+ "begin": "(<<)(\"|'|)(HTML)\\2",
476
+ "beginCaptures": {
477
+ "1": {
478
+ "name": "keyword.operator.heredoc.shell"
479
+ },
480
+ "3": {
481
+ "name": "keyword.control.heredoc-token.shell"
482
+ }
483
+ },
484
+ "captures": {
485
+ "0": {
486
+ "name": "punctuation.definition.string.shell"
487
+ }
488
+ },
489
+ "contentName": "text.html.embedded.shell",
490
+ "end": "^(HTML)\\b",
491
+ "endCaptures": {
492
+ "1": {
493
+ "name": "keyword.control.heredoc-token.shell"
494
+ }
495
+ },
496
+ "name": "string.unquoted.heredoc.html.shell",
497
+ "patterns": [
498
+ {
499
+ "include": "text.html.basic"
500
+ }
501
+ ]
502
+ },
503
+ {
504
+ "begin": "(<<)-(\"|'|)(MARKDOWN)\\2",
505
+ "beginCaptures": {
506
+ "1": {
507
+ "name": "keyword.operator.heredoc.shell"
508
+ },
509
+ "3": {
510
+ "name": "keyword.control.heredoc-token.shell"
511
+ }
512
+ },
513
+ "captures": {
514
+ "0": {
515
+ "name": "punctuation.definition.string.shell"
516
+ }
517
+ },
518
+ "contentName": "text.html.markdown.embedded.shell",
519
+ "end": "^\\t*(MARKDOWN)\\b",
520
+ "endCaptures": {
521
+ "1": {
522
+ "name": "keyword.control.heredoc-token.shell"
523
+ }
524
+ },
525
+ "name": "string.unquoted.heredoc.no-indent.markdown.shell",
526
+ "patterns": [
527
+ {
528
+ "include": "text.html.markdown"
529
+ }
530
+ ]
531
+ },
532
+ {
533
+ "begin": "(<<)(\"|'|)(MARKDOWN)\\2",
534
+ "beginCaptures": {
535
+ "1": {
536
+ "name": "keyword.operator.heredoc.shell"
537
+ },
538
+ "3": {
539
+ "name": "keyword.control.heredoc-token.shell"
540
+ }
541
+ },
542
+ "captures": {
543
+ "0": {
544
+ "name": "punctuation.definition.string.shell"
545
+ }
546
+ },
547
+ "contentName": "text.html.markdown.embedded.shell",
548
+ "end": "^(MARKDOWN)\\b",
549
+ "endCaptures": {
550
+ "1": {
551
+ "name": "keyword.control.heredoc-token.shell"
552
+ }
553
+ },
554
+ "name": "string.unquoted.heredoc.markdown.shell",
555
+ "patterns": [
556
+ {
557
+ "include": "text.html.markdown"
558
+ }
559
+ ]
560
+ },
561
+ {
562
+ "begin": "(<<)-(\"|'|)(TEXTILE)\\2",
563
+ "beginCaptures": {
564
+ "1": {
565
+ "name": "keyword.operator.heredoc.shell"
566
+ },
567
+ "3": {
568
+ "name": "keyword.control.heredoc-token.shell"
569
+ }
570
+ },
571
+ "captures": {
572
+ "0": {
573
+ "name": "punctuation.definition.string.shell"
574
+ }
575
+ },
576
+ "contentName": "text.html.textile.embedded.shell",
577
+ "end": "^\\t*(TEXTILE)\\b",
578
+ "endCaptures": {
579
+ "1": {
580
+ "name": "keyword.control.heredoc-token.shell"
581
+ }
582
+ },
583
+ "name": "string.unquoted.heredoc.no-indent.textile.shell",
584
+ "patterns": [
585
+ {
586
+ "include": "text.html.textile"
587
+ }
588
+ ]
589
+ },
590
+ {
591
+ "begin": "(<<)(\"|'|)(TEXTILE)\\2",
592
+ "beginCaptures": {
593
+ "1": {
594
+ "name": "keyword.operator.heredoc.shell"
595
+ },
596
+ "3": {
597
+ "name": "keyword.control.heredoc-token.shell"
598
+ }
599
+ },
600
+ "captures": {
601
+ "0": {
602
+ "name": "punctuation.definition.string.shell"
603
+ }
604
+ },
605
+ "contentName": "text.html.textile.embedded.shell",
606
+ "end": "^(TEXTILE)\\b",
607
+ "endCaptures": {
608
+ "1": {
609
+ "name": "keyword.control.heredoc-token.shell"
610
+ }
611
+ },
612
+ "name": "string.unquoted.heredoc.textile.shell",
613
+ "patterns": [
614
+ {
615
+ "include": "text.html.textile"
616
+ }
617
+ ]
618
+ },
619
+ {
620
+ "begin": "(<<)-(\"|'|)\\\\?(\\w+)\\2",
621
+ "beginCaptures": {
622
+ "1": {
623
+ "name": "keyword.operator.heredoc.shell"
624
+ },
625
+ "3": {
626
+ "name": "keyword.control.heredoc-token.shell"
627
+ }
628
+ },
629
+ "captures": {
630
+ "0": {
631
+ "name": "punctuation.definition.string.shell"
632
+ }
633
+ },
634
+ "end": "^\\t*(\\3)\\b",
635
+ "endCaptures": {
636
+ "1": {
637
+ "name": "keyword.control.heredoc-token.shell"
638
+ }
639
+ },
640
+ "name": "string.unquoted.heredoc.no-indent.shell"
641
+ },
642
+ {
643
+ "begin": "(<<)(\"|'|)\\\\?(\\w+)\\2",
644
+ "beginCaptures": {
645
+ "1": {
646
+ "name": "keyword.operator.heredoc.shell"
647
+ },
648
+ "3": {
649
+ "name": "keyword.control.heredoc-token.shell"
650
+ }
651
+ },
652
+ "captures": {
653
+ "0": {
654
+ "name": "punctuation.definition.string.shell"
655
+ }
656
+ },
657
+ "end": "^(\\3)\\b",
658
+ "endCaptures": {
659
+ "1": {
660
+ "name": "keyword.control.heredoc-token.shell"
661
+ }
662
+ },
663
+ "name": "string.unquoted.heredoc.shell"
664
+ }
665
+ ]
666
+ },
667
+ "herestring": {
668
+ "patterns": [
669
+ {
670
+ "captures": {
671
+ "1": {
672
+ "name": "keyword.operator.herestring.shell"
673
+ },
674
+ "2": {
675
+ "name": "string.quoted.single.herestring.shell"
676
+ },
677
+ "3": {
678
+ "name": "punctuation.definition.string.begin.shell"
679
+ },
680
+ "4": {
681
+ "name": "punctuation.definition.string.end.shell"
682
+ }
683
+ },
684
+ "match": "(<<<)((')[^']*('))",
685
+ "name": "meta.herestring.shell"
686
+ },
687
+ {
688
+ "captures": {
689
+ "1": {
690
+ "name": "keyword.operator.herestring.shell"
691
+ },
692
+ "2": {
693
+ "name": "string.quoted.double.herestring.shell"
694
+ },
695
+ "3": {
696
+ "name": "punctuation.definition.string.begin.shell"
697
+ },
698
+ "6": {
699
+ "name": "punctuation.definition.string.end.shell"
700
+ }
701
+ },
702
+ "match": "(<<<)((\")(\\\\(\"|\\\\)|[^\"])*(\"))",
703
+ "name": "meta.herestring.shell"
704
+ },
705
+ {
706
+ "captures": {
707
+ "1": {
708
+ "name": "keyword.operator.herestring.shell"
709
+ },
710
+ "2": {
711
+ "name": "string.unquoted.herestring.shell"
712
+ }
713
+ },
714
+ "match": "(<<<)(([^\\s\\\\]|\\\\.)+)",
715
+ "name": "meta.herestring.shell"
716
+ }
717
+ ]
718
+ },
719
+ "interpolation": {
720
+ "patterns": [
721
+ {
722
+ "begin": "\\$\\({2}",
723
+ "beginCaptures": {
724
+ "0": {
725
+ "name": "punctuation.definition.string.begin.shell"
726
+ }
727
+ },
728
+ "end": "\\){2}",
729
+ "endCaptures": {
730
+ "0": {
731
+ "name": "punctuation.definition.string.end.shell"
732
+ }
733
+ },
734
+ "name": "string.other.math.shell",
735
+ "patterns": [
736
+ {
737
+ "include": "#math"
738
+ }
739
+ ]
740
+ },
741
+ {
742
+ "begin": "`",
743
+ "beginCaptures": {
744
+ "0": {
745
+ "name": "punctuation.definition.string.begin.shell"
746
+ }
747
+ },
748
+ "end": "`",
749
+ "endCaptures": {
750
+ "0": {
751
+ "name": "punctuation.definition.string.end.shell"
752
+ }
753
+ },
754
+ "name": "string.interpolated.backtick.shell",
755
+ "patterns": [
756
+ {
757
+ "match": "\\\\[`\\\\$]",
758
+ "name": "constant.character.escape.shell"
759
+ },
760
+ {
761
+ "include": "$self"
762
+ }
763
+ ]
764
+ },
765
+ {
766
+ "begin": "\\$\\(",
767
+ "beginCaptures": {
768
+ "0": {
769
+ "name": "punctuation.definition.string.begin.shell"
770
+ }
771
+ },
772
+ "end": "\\)",
773
+ "endCaptures": {
774
+ "0": {
775
+ "name": "punctuation.definition.string.end.shell"
776
+ }
777
+ },
778
+ "name": "string.interpolated.dollar.shell",
779
+ "patterns": [
780
+ {
781
+ "include": "$self"
782
+ }
783
+ ]
784
+ }
785
+ ]
786
+ },
787
+ "keyword": {
788
+ "patterns": [
789
+ {
790
+ "match": "\\b(?:then|else|elif|fi|for|in|do|done|select|case|continue|esac|while|until|return)\\b",
791
+ "name": "keyword.control.shell"
792
+ },
793
+ {
794
+ "match": "(?<![-/])\\b(?:export|declare|typeset|local|readonly)\\b",
795
+ "name": "storage.modifier.shell"
796
+ }
797
+ ]
798
+ },
799
+ "list": {
800
+ "patterns": [
801
+ {
802
+ "match": ";|&&|&|\\|\\|",
803
+ "name": "keyword.operator.list.shell"
804
+ }
805
+ ]
806
+ },
807
+ "logical-expression": {
808
+ "patterns": [
809
+ {
810
+ "comment": "do we want a special rule for ( expr )?",
811
+ "match": "=[=~]?|!=?|<|>|&&|\\|\\|",
812
+ "name": "keyword.operator.logical.shell"
813
+ },
814
+ {
815
+ "match": "(?<!\\S)-(nt|ot|ef|eq|ne|l[te]|g[te]|[a-hknoprstuwxzOGLSN])",
816
+ "name": "keyword.operator.logical.shell"
817
+ }
818
+ ]
819
+ },
820
+ "loop": {
821
+ "patterns": [
822
+ {
823
+ "begin": "\\b(for)\\s+(?=\\({2})",
824
+ "captures": {
825
+ "1": {
826
+ "name": "keyword.control.shell"
827
+ }
828
+ },
829
+ "end": "\\b(done)\\b",
830
+ "name": "meta.scope.for-loop.shell",
831
+ "patterns": [
832
+ {
833
+ "include": "$self"
834
+ }
835
+ ]
836
+ },
837
+ {
838
+ "begin": "\\b(for)\\s+((?:[^\\s\\\\]|\\\\.)+)\\b",
839
+ "beginCaptures": {
840
+ "1": {
841
+ "name": "keyword.control.shell"
842
+ },
843
+ "2": {
844
+ "name": "variable.other.loop.shell"
845
+ }
846
+ },
847
+ "end": "\\b(done)\\b",
848
+ "endCaptures": {
849
+ "1": {
850
+ "name": "keyword.control.shell"
851
+ }
852
+ },
853
+ "name": "meta.scope.for-in-loop.shell",
854
+ "patterns": [
855
+ {
856
+ "include": "$self"
857
+ }
858
+ ]
859
+ },
860
+ {
861
+ "begin": "\\b(while|until)\\b",
862
+ "captures": {
863
+ "1": {
864
+ "name": "keyword.control.shell"
865
+ }
866
+ },
867
+ "end": "\\b(done)\\b",
868
+ "name": "meta.scope.while-loop.shell",
869
+ "patterns": [
870
+ {
871
+ "include": "$self"
872
+ }
873
+ ]
874
+ },
875
+ {
876
+ "begin": "\\b(select)\\s+((?:[^\\s\\\\]|\\\\.)+)\\b",
877
+ "beginCaptures": {
878
+ "1": {
879
+ "name": "keyword.control.shell"
880
+ },
881
+ "2": {
882
+ "name": "variable.other.loop.shell"
883
+ }
884
+ },
885
+ "end": "\\b(done)\\b",
886
+ "endCaptures": {
887
+ "1": {
888
+ "name": "keyword.control.shell"
889
+ }
890
+ },
891
+ "name": "meta.scope.select-block.shell",
892
+ "patterns": [
893
+ {
894
+ "include": "$self"
895
+ }
896
+ ]
897
+ },
898
+ {
899
+ "begin": "\\b(case)\\b",
900
+ "captures": {
901
+ "1": {
902
+ "name": "keyword.control.shell"
903
+ }
904
+ },
905
+ "end": "\\b(esac)\\b",
906
+ "name": "meta.scope.case-block.shell",
907
+ "patterns": [
908
+ {
909
+ "begin": "\\b(?:in)\\b",
910
+ "beginCaptures": {
911
+ "1": {
912
+ "name": "keyword.control.shell"
913
+ }
914
+ },
915
+ "end": "(?=\\b(?:esac)\\b)",
916
+ "name": "meta.scope.case-body.shell",
917
+ "patterns": [
918
+ {
919
+ "include": "#comment"
920
+ },
921
+ {
922
+ "include": "#case-clause"
923
+ },
924
+ {
925
+ "include": "$self"
926
+ }
927
+ ]
928
+ },
929
+ {
930
+ "include": "$self"
931
+ }
932
+ ]
933
+ },
934
+ {
935
+ "begin": "\\b(if)(?!s*=)",
936
+ "captures": {
937
+ "1": {
938
+ "name": "keyword.control.shell"
939
+ }
940
+ },
941
+ "end": "\\b(fi)\\b",
942
+ "name": "meta.scope.if-block.shell",
943
+ "patterns": [
944
+ {
945
+ "include": "$self"
946
+ }
947
+ ]
948
+ }
949
+ ]
950
+ },
951
+ "math": {
952
+ "patterns": [
953
+ {
954
+ "include": "#variable"
955
+ },
956
+ {
957
+ "match": "\\+{1,2}|-{1,2}|!|~|\\*{1,2}|/|%|<[<=]?|>[>=]?|==|!=|^|\\|{1,2}|&{1,2}|\\?|\\:|,|=|[*/%+\\-&^|]=|<<=|>>=",
958
+ "name": "keyword.operator.arithmetic.shell"
959
+ },
960
+ {
961
+ "match": "0[xX]\\h+",
962
+ "name": "constant.numeric.hex.shell"
963
+ },
964
+ {
965
+ "match": "0\\d+",
966
+ "name": "constant.numeric.octal.shell"
967
+ },
968
+ {
969
+ "match": "\\d{1,2}#[0-9a-zA-Z@_]+",
970
+ "name": "constant.numeric.other.shell"
971
+ },
972
+ {
973
+ "match": "\\d+",
974
+ "name": "constant.numeric.integer.shell"
975
+ }
976
+ ]
977
+ },
978
+ "pathname": {
979
+ "patterns": [
980
+ {
981
+ "match": "(?<=\\s|:|=|^)~",
982
+ "name": "keyword.operator.tilde.shell"
983
+ },
984
+ {
985
+ "match": "\\*|\\?",
986
+ "name": "keyword.operator.glob.shell"
987
+ },
988
+ {
989
+ "begin": "([?*+@!])(\\()",
990
+ "beginCaptures": {
991
+ "1": {
992
+ "name": "keyword.operator.extglob.shell"
993
+ },
994
+ "2": {
995
+ "name": "punctuation.definition.extglob.shell"
996
+ }
997
+ },
998
+ "end": "(\\))",
999
+ "endCaptures": {
1000
+ "1": {
1001
+ "name": "punctuation.definition.extglob.shell"
1002
+ }
1003
+ },
1004
+ "name": "meta.structure.extglob.shell",
1005
+ "patterns": [
1006
+ {
1007
+ "include": "$self"
1008
+ }
1009
+ ]
1010
+ }
1011
+ ]
1012
+ },
1013
+ "pipeline": {
1014
+ "patterns": [
1015
+ {
1016
+ "match": "\\b(time)\\b",
1017
+ "name": "keyword.other.shell"
1018
+ },
1019
+ {
1020
+ "match": "[|!]",
1021
+ "name": "keyword.operator.pipe.shell"
1022
+ }
1023
+ ]
1024
+ },
1025
+ "redirection": {
1026
+ "patterns": [
1027
+ {
1028
+ "begin": "[><]\\(",
1029
+ "beginCaptures": {
1030
+ "0": {
1031
+ "name": "punctuation.definition.string.begin.shell"
1032
+ }
1033
+ },
1034
+ "end": "\\)",
1035
+ "endCaptures": {
1036
+ "0": {
1037
+ "name": "punctuation.definition.string.end.shell"
1038
+ }
1039
+ },
1040
+ "name": "string.interpolated.process-substitution.shell",
1041
+ "patterns": [
1042
+ {
1043
+ "include": "$self"
1044
+ }
1045
+ ]
1046
+ },
1047
+ {
1048
+ "comment": "valid: &>word >&word >word [n]>&[n] [n]<word [n]>word [n]>>word [n]<&word (last one is duplicate)",
1049
+ "match": "&>|\\d*>&\\d*|\\d*(>>|>|<)|\\d*<&|\\d*<>",
1050
+ "name": "keyword.operator.redirect.shell"
1051
+ }
1052
+ ]
1053
+ },
1054
+ "string": {
1055
+ "patterns": [
1056
+ {
1057
+ "match": "\\\\.",
1058
+ "name": "constant.character.escape.shell"
1059
+ },
1060
+ {
1061
+ "begin": "'",
1062
+ "beginCaptures": {
1063
+ "0": {
1064
+ "name": "punctuation.definition.string.begin.shell"
1065
+ }
1066
+ },
1067
+ "end": "'",
1068
+ "endCaptures": {
1069
+ "0": {
1070
+ "name": "punctuation.definition.string.end.shell"
1071
+ }
1072
+ },
1073
+ "name": "string.quoted.single.shell"
1074
+ },
1075
+ {
1076
+ "begin": "\\$?\"",
1077
+ "beginCaptures": {
1078
+ "0": {
1079
+ "name": "punctuation.definition.string.begin.shell"
1080
+ }
1081
+ },
1082
+ "end": "\"",
1083
+ "endCaptures": {
1084
+ "0": {
1085
+ "name": "punctuation.definition.string.end.shell"
1086
+ }
1087
+ },
1088
+ "name": "string.quoted.double.shell",
1089
+ "patterns": [
1090
+ {
1091
+ "match": "\\\\[\\$`\"\\\\\\n]",
1092
+ "name": "constant.character.escape.shell"
1093
+ },
1094
+ {
1095
+ "include": "#variable"
1096
+ },
1097
+ {
1098
+ "include": "#interpolation"
1099
+ }
1100
+ ]
1101
+ },
1102
+ {
1103
+ "begin": "\\$'",
1104
+ "beginCaptures": {
1105
+ "0": {
1106
+ "name": "punctuation.definition.string.begin.shell"
1107
+ }
1108
+ },
1109
+ "end": "'",
1110
+ "endCaptures": {
1111
+ "0": {
1112
+ "name": "punctuation.definition.string.end.shell"
1113
+ }
1114
+ },
1115
+ "name": "string.quoted.single.dollar.shell",
1116
+ "patterns": [
1117
+ {
1118
+ "match": "\\\\(a|b|e|f|n|r|t|v|\\\\|')",
1119
+ "name": "constant.character.escape.ansi-c.shell"
1120
+ },
1121
+ {
1122
+ "match": "\\\\[0-9]{3}",
1123
+ "name": "constant.character.escape.octal.shell"
1124
+ },
1125
+ {
1126
+ "match": "\\\\x[0-9a-fA-F]{2}",
1127
+ "name": "constant.character.escape.hex.shell"
1128
+ },
1129
+ {
1130
+ "match": "\\\\c.",
1131
+ "name": "constant.character.escape.control-char.shell"
1132
+ }
1133
+ ]
1134
+ }
1135
+ ]
1136
+ },
1137
+ "support": {
1138
+ "patterns": [
1139
+ {
1140
+ "match": "(?<=^|\\s)(?::|\\.)(?=\\s|;|&|$)",
1141
+ "name": "support.function.builtin.shell"
1142
+ },
1143
+ {
1144
+ "match": "(?<![-/])\\b(?:alias|bg|bind|break|builtin|caller|cd|command|compgen|complete|dirs|disown|echo|enable|eval|exec|exit|false|fc|fg|getopts|hash|help|history|jobs|kill|let|logout|popd|printf|pushd|pwd|read|readonly|set|shift|shopt|source|suspend|test|times|trap|true|type|ulimit|umask|unalias|unset|wait)\\b",
1145
+ "name": "support.function.builtin.shell"
1146
+ }
1147
+ ]
1148
+ },
1149
+ "variable": {
1150
+ "patterns": [
1151
+ {
1152
+ "captures": {
1153
+ "1": {
1154
+ "name": "punctuation.definition.variable.shell"
1155
+ }
1156
+ },
1157
+ "match": "(\\$)[a-zA-Z_][a-zA-Z0-9_]*",
1158
+ "name": "variable.other.normal.shell"
1159
+ },
1160
+ {
1161
+ "captures": {
1162
+ "1": {
1163
+ "name": "punctuation.definition.variable.shell"
1164
+ }
1165
+ },
1166
+ "match": "(\\$)[-*@#?$!0_]",
1167
+ "name": "variable.other.special.shell"
1168
+ },
1169
+ {
1170
+ "captures": {
1171
+ "1": {
1172
+ "name": "punctuation.definition.variable.shell"
1173
+ }
1174
+ },
1175
+ "match": "(\\$)[1-9]",
1176
+ "name": "variable.other.positional.shell"
1177
+ },
1178
+ {
1179
+ "begin": "\\$\\{",
1180
+ "captures": {
1181
+ "0": {
1182
+ "name": "punctuation.definition.variable.shell"
1183
+ }
1184
+ },
1185
+ "end": "\\}",
1186
+ "name": "variable.other.bracket.shell",
1187
+ "patterns": [
1188
+ {
1189
+ "match": "!|:[-=?]?|\\*|@|#{1,2}|%{1,2}|/",
1190
+ "name": "keyword.operator.expansion.shell"
1191
+ },
1192
+ {
1193
+ "captures": {
1194
+ "1": {
1195
+ "name": "punctuation.section.array.shell"
1196
+ },
1197
+ "3": {
1198
+ "name": "punctuation.section.array.shell"
1199
+ }
1200
+ },
1201
+ "match": "(\\[)([^\\]]+)(\\])"
1202
+ },
1203
+ {
1204
+ "include": "#string"
1205
+ }
1206
+ ]
1207
+ }
1208
+ ]
1209
+ }
1210
+ },
1211
+ "scopeName": "source.shell"
1212
+ }