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,1385 @@
1
+ {
2
+ "fileTypes": [
3
+ "applescript",
4
+ "script editor"
5
+ ],
6
+ "firstLineMatch": "^#!.*(osascript)",
7
+ "keyEquivalent": "^~A",
8
+ "name": "AppleScript",
9
+ "patterns": [
10
+ {
11
+ "include": "#blocks"
12
+ },
13
+ {
14
+ "include": "#inline"
15
+ }
16
+ ],
17
+ "repository": {
18
+ "attributes.considering-ignoring": {
19
+ "patterns": [
20
+ {
21
+ "match": ",",
22
+ "name": "punctuation.separator.array.attributes.applescript"
23
+ },
24
+ {
25
+ "match": "\\b(and)\\b",
26
+ "name": "keyword.control.attributes.and.applescript"
27
+ },
28
+ {
29
+ "match": "\\b(?i:case|diacriticals|hyphens|numeric\\s+strings|punctuation|white\\s+space)\\b",
30
+ "name": "constant.other.attributes.text.applescript"
31
+ },
32
+ {
33
+ "match": "\\b(?i:application\\s+responses)\\b",
34
+ "name": "constant.other.attributes.application.applescript"
35
+ }
36
+ ]
37
+ },
38
+ "blocks": {
39
+ "patterns": [
40
+ {
41
+ "begin": "^\\s*(script)\\s+(\\w+)",
42
+ "beginCaptures": {
43
+ "1": {
44
+ "name": "keyword.control.script.applescript"
45
+ },
46
+ "2": {
47
+ "name": "entity.name.type.script-object.applescript"
48
+ }
49
+ },
50
+ "end": "^\\s*(end(?:\\s+script)?)(?=\\s*(--.*?)?$)",
51
+ "endCaptures": {
52
+ "1": {
53
+ "name": "keyword.control.script.applescript"
54
+ }
55
+ },
56
+ "name": "meta.block.script.applescript",
57
+ "patterns": [
58
+ {
59
+ "include": "$self"
60
+ }
61
+ ]
62
+ },
63
+ {
64
+ "begin": "^(?x)\n\t\t\t\t\t\t\\s*(to|on)\\s+ \t\t\t\t\t# \"on\" or \"to\"\n\t\t\t\t\t\t(\\w+)\t\t\t\t\t\t\t# function name\n\t\t\t\t\t\t(\\()\t\t\t\t\t\t\t# opening paren\n\t\t\t\t\t\t\t((?:[\\s,:\\{\\}]*(?:\\w+)?)*)\t# parameters\n\t\t\t\t\t\t(\\))\t\t\t\t\t\t\t# closing paren\n\t\t\t\t\t",
65
+ "beginCaptures": {
66
+ "1": {
67
+ "name": "keyword.control.function.applescript"
68
+ },
69
+ "2": {
70
+ "name": "entity.name.function.handler.applescript"
71
+ },
72
+ "3": {
73
+ "name": "punctuation.definition.parameters.begin.applescript"
74
+ },
75
+ "4": {
76
+ "name": "variable.parameter.handler.applescript"
77
+ },
78
+ "5": {
79
+ "name": "punctuation.definition.parameters.end.applescript"
80
+ }
81
+ },
82
+ "comment": "\n\t\t\t\t\t\tThis is not a very well-designed rule. For now,\n\t\t\t\t\t\twe can leave it like this though, as it sorta works.\n\t\t\t\t\t",
83
+ "end": "^\\s*(end)(?:\\s+(\\2))?(?=\\s*(--.*?)?$)",
84
+ "endCaptures": {
85
+ "1": {
86
+ "name": "keyword.control.function.applescript"
87
+ }
88
+ },
89
+ "name": "meta.function.positional.applescript",
90
+ "patterns": [
91
+ {
92
+ "include": "$self"
93
+ }
94
+ ]
95
+ },
96
+ {
97
+ "begin": "^(?x)\n\t\t\t\t\t\t\\s*(to|on)\\s+ \t\t\t\t\t# \"on\" or \"to\"\n\t\t\t\t\t\t(\\w+)\t\t\t\t\t\t\t# function name\n\t\t\t\t\t\t(?:\\s+\n\t\t\t\t\t\t\t(of|in)\\s+\t\t\t\t\t# \"of\" or \"in\"\n\t\t\t\t\t\t\t(\\w+)\t\t\t\t\t\t# direct parameter\n\t\t\t\t\t\t)?\n\t\t\t\t\t\t(?=\\s+(above|against|apart\\s+from|around|aside\\s+from|at|below|beneath|beside|between|by|for|from|instead\\s+of|into|on|onto|out\\s+of|over|thru|under)\\b)\n\t\t\t\t\t",
98
+ "beginCaptures": {
99
+ "1": {
100
+ "name": "keyword.control.function.applescript"
101
+ },
102
+ "2": {
103
+ "name": "entity.name.function.handler.applescript"
104
+ },
105
+ "3": {
106
+ "name": "keyword.control.function.applescript"
107
+ },
108
+ "4": {
109
+ "name": "variable.parameter.handler.direct.applescript"
110
+ }
111
+ },
112
+ "comment": "TODO: match `given` parameters",
113
+ "end": "^\\s*(end)(?:\\s+(\\2))?(?=\\s*(--.*?)?$)",
114
+ "endCaptures": {
115
+ "1": {
116
+ "name": "keyword.control.function.applescript"
117
+ }
118
+ },
119
+ "name": "meta.function.prepositional.applescript",
120
+ "patterns": [
121
+ {
122
+ "captures": {
123
+ "1": {
124
+ "name": "keyword.control.preposition.applescript"
125
+ },
126
+ "2": {
127
+ "name": "variable.parameter.handler.applescript"
128
+ }
129
+ },
130
+ "match": "\\b(?i:above|against|apart\\s+from|around|aside\\s+from|at|below|beneath|beside|between|by|for|from|instead\\s+of|into|on|onto|out\\s+of|over|thru|under)\\s+(\\w+)\\b"
131
+ },
132
+ {
133
+ "include": "$self"
134
+ }
135
+ ]
136
+ },
137
+ {
138
+ "begin": "^(?x)\n\t\t\t\t\t\t\\s*(to|on)\\s+ \t\t\t\t\t# \"on\" or \"to\"\n\t\t\t\t\t\t(\\w+)\t\t\t\t\t\t\t# function name\n\t\t\t\t\t\t(?=\\s*(--.*?)?$)\t\t\t\t# nothing else\n\t\t\t\t\t",
139
+ "beginCaptures": {
140
+ "1": {
141
+ "name": "keyword.control.function.applescript"
142
+ },
143
+ "2": {
144
+ "name": "entity.name.function.handler.applescript"
145
+ }
146
+ },
147
+ "end": "^\\s*(end)(?:\\s+(\\2))?(?=\\s*(--.*?)?$)",
148
+ "endCaptures": {
149
+ "1": {
150
+ "name": "keyword.control.function.applescript"
151
+ }
152
+ },
153
+ "name": "meta.function.parameterless.applescript",
154
+ "patterns": [
155
+ {
156
+ "include": "$self"
157
+ }
158
+ ]
159
+ },
160
+ {
161
+ "include": "#blocks.tell"
162
+ },
163
+ {
164
+ "include": "#blocks.repeat"
165
+ },
166
+ {
167
+ "include": "#blocks.statement"
168
+ },
169
+ {
170
+ "include": "#blocks.other"
171
+ }
172
+ ]
173
+ },
174
+ "blocks.other": {
175
+ "patterns": [
176
+ {
177
+ "begin": "^\\s*(considering)\\b",
178
+ "end": "^\\s*(end(?:\\s+considering)?)(?=\\s*(--.*?)?$)",
179
+ "name": "meta.block.considering.applescript",
180
+ "patterns": [
181
+ {
182
+ "begin": "(?<=considering)",
183
+ "end": "(?<!¬)$",
184
+ "name": "meta.array.attributes.considering.applescript",
185
+ "patterns": [
186
+ {
187
+ "include": "#attributes.considering-ignoring"
188
+ }
189
+ ]
190
+ },
191
+ {
192
+ "begin": "(?<=ignoring)",
193
+ "end": "(?<!¬)$",
194
+ "name": "meta.array.attributes.ignoring.applescript",
195
+ "patterns": [
196
+ {
197
+ "include": "#attributes.considering-ignoring"
198
+ }
199
+ ]
200
+ },
201
+ {
202
+ "match": "\\b(but)\\b",
203
+ "name": "keyword.control.but.applescript"
204
+ },
205
+ {
206
+ "include": "$self"
207
+ }
208
+ ]
209
+ },
210
+ {
211
+ "begin": "^\\s*(ignoring)\\b",
212
+ "end": "^\\s*(end(?:\\s+ignoring)?)(?=\\s*(--.*?)?$)",
213
+ "name": "meta.block.ignoring.applescript",
214
+ "patterns": [
215
+ {
216
+ "begin": "(?<=considering)",
217
+ "end": "(?<!¬)$",
218
+ "name": "meta.array.attributes.considering.applescript",
219
+ "patterns": [
220
+ {
221
+ "include": "#attributes.considering-ignoring"
222
+ }
223
+ ]
224
+ },
225
+ {
226
+ "begin": "(?<=ignoring)",
227
+ "end": "(?<!¬)$",
228
+ "name": "meta.array.attributes.ignoring.applescript",
229
+ "patterns": [
230
+ {
231
+ "include": "#attributes.considering-ignoring"
232
+ }
233
+ ]
234
+ },
235
+ {
236
+ "match": "\\b(but)\\b",
237
+ "name": "keyword.control.but.applescript"
238
+ },
239
+ {
240
+ "include": "$self"
241
+ }
242
+ ]
243
+ },
244
+ {
245
+ "begin": "^\\s*(if)\\b",
246
+ "beginCaptures": {
247
+ "1": {
248
+ "name": "keyword.control.if.applescript"
249
+ }
250
+ },
251
+ "end": "^\\s*(end(?:\\s+if)?)(?=\\s*(--.*?)?$)",
252
+ "endCaptures": {
253
+ "1": {
254
+ "name": "keyword.control.end.applescript"
255
+ }
256
+ },
257
+ "name": "meta.block.if.applescript",
258
+ "patterns": [
259
+ {
260
+ "match": "\\b(then)\\b",
261
+ "name": "keyword.control.then.applescript"
262
+ },
263
+ {
264
+ "match": "\\b(else\\s+if)\\b",
265
+ "name": "keyword.control.else-if.applescript"
266
+ },
267
+ {
268
+ "match": "\\b(else)\\b",
269
+ "name": "keyword.control.else.applescript"
270
+ },
271
+ {
272
+ "include": "$self"
273
+ }
274
+ ]
275
+ },
276
+ {
277
+ "begin": "^\\s*(try)\\b",
278
+ "beginCaptures": {
279
+ "1": {
280
+ "name": "keyword.control.try.applescript"
281
+ }
282
+ },
283
+ "end": "^\\s*(end(?:\\s+(try|error))?)(?=\\s*(--.*?)?$)",
284
+ "endCaptures": {
285
+ "1": {
286
+ "name": "keyword.control.end.applescript"
287
+ }
288
+ },
289
+ "name": "meta.block.try.applescript",
290
+ "patterns": [
291
+ {
292
+ "begin": "^\\s*(on\\s+error)\\b",
293
+ "beginCaptures": {
294
+ "1": {
295
+ "name": "keyword.control.exception.on-error.applescript"
296
+ }
297
+ },
298
+ "end": "(?<!¬)$",
299
+ "name": "meta.property.error.applescript",
300
+ "patterns": [
301
+ {
302
+ "match": "\\b(?i:number|partial|from|to)\\b",
303
+ "name": "keyword.control.exception.modifier.applescript"
304
+ },
305
+ {
306
+ "include": "#inline"
307
+ }
308
+ ]
309
+ },
310
+ {
311
+ "include": "$self"
312
+ }
313
+ ]
314
+ },
315
+ {
316
+ "begin": "^\\s*(using\\s+terms\\s+from)\\b",
317
+ "beginCaptures": {
318
+ "1": {
319
+ "name": "keyword.control.terms.applescript"
320
+ }
321
+ },
322
+ "end": "^\\s*(end(?:\\s+using\\s+terms\\s+from)?)(?=\\s*(--.*?)?$)",
323
+ "endCaptures": {
324
+ "1": {
325
+ "name": "keyword.control.end.applescript"
326
+ }
327
+ },
328
+ "name": "meta.block.terms.applescript",
329
+ "patterns": [
330
+ {
331
+ "include": "$self"
332
+ }
333
+ ]
334
+ },
335
+ {
336
+ "begin": "^\\s*(with\\s+timeout(\\s+of)?)\\b",
337
+ "beginCaptures": {
338
+ "1": {
339
+ "name": "keyword.control.timeout.applescript"
340
+ }
341
+ },
342
+ "end": "^\\s*(end(?:\\s+timeout)?)(?=\\s*(--.*?)?$)",
343
+ "endCaptures": {
344
+ "1": {
345
+ "name": "keyword.control.end.applescript"
346
+ }
347
+ },
348
+ "name": "meta.block.timeout.applescript",
349
+ "patterns": [
350
+ {
351
+ "include": "$self"
352
+ }
353
+ ]
354
+ },
355
+ {
356
+ "begin": "^\\s*(with\\s+transaction(\\s+of)?)\\b",
357
+ "beginCaptures": {
358
+ "1": {
359
+ "name": "keyword.control.transaction.applescript"
360
+ }
361
+ },
362
+ "end": "^\\s*(end(?:\\s+transaction)?)(?=\\s*(--.*?)?$)",
363
+ "endCaptures": {
364
+ "1": {
365
+ "name": "keyword.control.end.applescript"
366
+ }
367
+ },
368
+ "name": "meta.block.transaction.applescript",
369
+ "patterns": [
370
+ {
371
+ "include": "$self"
372
+ }
373
+ ]
374
+ }
375
+ ]
376
+ },
377
+ "blocks.repeat": {
378
+ "patterns": [
379
+ {
380
+ "begin": "^\\s*(repeat)\\s+(until)\\b",
381
+ "beginCaptures": {
382
+ "1": {
383
+ "name": "keyword.control.repeat.applescript"
384
+ },
385
+ "2": {
386
+ "name": "keyword.control.until.applescript"
387
+ }
388
+ },
389
+ "end": "^\\s*(end(?:\\s+repeat)?)(?=\\s*(--.*?)?$)",
390
+ "endCaptures": {
391
+ "1": {
392
+ "name": "keyword.control.end.applescript"
393
+ }
394
+ },
395
+ "name": "meta.block.repeat.until.applescript",
396
+ "patterns": [
397
+ {
398
+ "include": "$self"
399
+ }
400
+ ]
401
+ },
402
+ {
403
+ "begin": "^\\s*(repeat)\\s+(while)\\b",
404
+ "beginCaptures": {
405
+ "1": {
406
+ "name": "keyword.control.repeat.applescript"
407
+ },
408
+ "2": {
409
+ "name": "keyword.control.while.applescript"
410
+ }
411
+ },
412
+ "end": "^\\s*(end(?:\\s+repeat)?)(?=\\s*(--.*?)?$)",
413
+ "endCaptures": {
414
+ "1": {
415
+ "name": "keyword.control.end.applescript"
416
+ }
417
+ },
418
+ "name": "meta.block.repeat.while.applescript",
419
+ "patterns": [
420
+ {
421
+ "include": "$self"
422
+ }
423
+ ]
424
+ },
425
+ {
426
+ "begin": "^\\s*(repeat)\\s+(with)\\s+(\\w+)\\b",
427
+ "beginCaptures": {
428
+ "1": {
429
+ "name": "keyword.control.repeat.applescript"
430
+ },
431
+ "2": {
432
+ "name": "keyword.control.until.applescript"
433
+ },
434
+ "3": {
435
+ "name": "variable.parameter.loop.applescript"
436
+ }
437
+ },
438
+ "end": "^\\s*(end(?:\\s+repeat)?)(?=\\s*(--.*?)?$)",
439
+ "endCaptures": {
440
+ "1": {
441
+ "name": "keyword.control.end.applescript"
442
+ }
443
+ },
444
+ "name": "meta.block.repeat.with.applescript",
445
+ "patterns": [
446
+ {
447
+ "match": "\\b(from|to|by)\\b",
448
+ "name": "keyword.control.modifier.range.applescript"
449
+ },
450
+ {
451
+ "match": "\\b(in)\\b",
452
+ "name": "keyword.control.modifier.list.applescript"
453
+ },
454
+ {
455
+ "include": "$self"
456
+ }
457
+ ]
458
+ },
459
+ {
460
+ "begin": "^\\s*(repeat)\\b(?=\\s*(--.*?)?$)",
461
+ "beginCaptures": {
462
+ "1": {
463
+ "name": "keyword.control.repeat.applescript"
464
+ }
465
+ },
466
+ "end": "^\\s*(end(?:\\s+repeat)?)(?=\\s*(--.*?)?$)",
467
+ "endCaptures": {
468
+ "1": {
469
+ "name": "keyword.control.end.applescript"
470
+ }
471
+ },
472
+ "name": "meta.block.repeat.forever.applescript",
473
+ "patterns": [
474
+ {
475
+ "include": "$self"
476
+ }
477
+ ]
478
+ },
479
+ {
480
+ "begin": "^\\s*(repeat)\\b",
481
+ "beginCaptures": {
482
+ "1": {
483
+ "name": "keyword.control.repeat.applescript"
484
+ }
485
+ },
486
+ "end": "^\\s*(end(?:\\s+repeat)?)(?=\\s*(--.*?)?$)",
487
+ "endCaptures": {
488
+ "1": {
489
+ "name": "keyword.control.end.applescript"
490
+ }
491
+ },
492
+ "name": "meta.block.repeat.times.applescript",
493
+ "patterns": [
494
+ {
495
+ "match": "\\b(times)\\b",
496
+ "name": "keyword.control.times.applescript"
497
+ },
498
+ {
499
+ "include": "$self"
500
+ }
501
+ ]
502
+ }
503
+ ]
504
+ },
505
+ "blocks.statement": {
506
+ "patterns": [
507
+ {
508
+ "begin": "\\b(prop(?:erty)?)\\s+(\\w+)\\b",
509
+ "beginCaptures": {
510
+ "1": {
511
+ "name": "keyword.control.def.property.applescript"
512
+ },
513
+ "2": {
514
+ "name": "variable.other.property.applescript"
515
+ }
516
+ },
517
+ "end": "(?<!¬)$",
518
+ "name": "meta.statement.property.applescript",
519
+ "patterns": [
520
+ {
521
+ "match": ":",
522
+ "name": "punctuation.separator.key-value.property.applescript"
523
+ },
524
+ {
525
+ "include": "#inline"
526
+ }
527
+ ]
528
+ },
529
+ {
530
+ "begin": "\\b(set)\\s+(\\w+)\\s+(to)\\b",
531
+ "beginCaptures": {
532
+ "1": {
533
+ "name": "keyword.control.def.set.applescript"
534
+ },
535
+ "2": {
536
+ "name": "variable.other.readwrite.set.applescript"
537
+ },
538
+ "3": {
539
+ "name": "keyword.control.def.set.applescript"
540
+ }
541
+ },
542
+ "end": "(?<!¬)$",
543
+ "name": "meta.statement.set.applescript",
544
+ "patterns": [
545
+ {
546
+ "include": "#inline"
547
+ }
548
+ ]
549
+ },
550
+ {
551
+ "begin": "\\b(local)\\b",
552
+ "beginCaptures": {
553
+ "1": {
554
+ "name": "keyword.control.def.local.applescript"
555
+ }
556
+ },
557
+ "end": "(?<!¬)$",
558
+ "name": "meta.statement.local.applescript",
559
+ "patterns": [
560
+ {
561
+ "match": ",",
562
+ "name": "punctuation.separator.variables.local.applescript"
563
+ },
564
+ {
565
+ "match": "\\b\\w+",
566
+ "name": "variable.other.readwrite.local.applescript"
567
+ },
568
+ {
569
+ "include": "#inline"
570
+ }
571
+ ]
572
+ },
573
+ {
574
+ "begin": "\\b(global)\\b",
575
+ "beginCaptures": {
576
+ "1": {
577
+ "name": "keyword.control.def.global.applescript"
578
+ }
579
+ },
580
+ "end": "(?<!¬)$",
581
+ "name": "meta.statement.global.applescript",
582
+ "patterns": [
583
+ {
584
+ "match": ",",
585
+ "name": "punctuation.separator.variables.global.applescript"
586
+ },
587
+ {
588
+ "match": "\\b\\w+",
589
+ "name": "variable.other.readwrite.global.applescript"
590
+ },
591
+ {
592
+ "include": "#inline"
593
+ }
594
+ ]
595
+ },
596
+ {
597
+ "begin": "\\b(error)\\b",
598
+ "beginCaptures": {
599
+ "1": {
600
+ "name": "keyword.control.exception.error.applescript"
601
+ }
602
+ },
603
+ "end": "(?<!¬)$",
604
+ "name": "meta.statement.error.applescript",
605
+ "patterns": [
606
+ {
607
+ "match": "\\b(number|partial|from|to)\\b",
608
+ "name": "keyword.control.exception.modifier.applescript"
609
+ },
610
+ {
611
+ "include": "#inline"
612
+ }
613
+ ]
614
+ },
615
+ {
616
+ "begin": "\\b(if)\\b(?=.*\\bthen\\b(?!\\s*(--.*?)?$))",
617
+ "beginCaptures": {
618
+ "1": {
619
+ "name": "keyword.control.if.applescript"
620
+ }
621
+ },
622
+ "end": "(?<!¬)$",
623
+ "name": "meta.statement.if-then.applescript",
624
+ "patterns": [
625
+ {
626
+ "include": "#inline"
627
+ }
628
+ ]
629
+ }
630
+ ]
631
+ },
632
+ "blocks.tell": {
633
+ "patterns": [
634
+ {
635
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\s+\"(?i:textmate)\")(?!.*\\bto(?!\\s+tell)\\b)",
636
+ "captures": {
637
+ "1": {
638
+ "name": "keyword.control.tell.applescript"
639
+ }
640
+ },
641
+ "comment": "tell Textmate",
642
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
643
+ "name": "meta.block.tell.application.textmate.applescript",
644
+ "patterns": [
645
+ {
646
+ "include": "#textmate"
647
+ },
648
+ {
649
+ "include": "#standard-suite"
650
+ },
651
+ {
652
+ "include": "$self"
653
+ }
654
+ ]
655
+ },
656
+ {
657
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\s+\"(?i:finder)\")(?!.*\\bto(?!\\s+tell)\\b)",
658
+ "captures": {
659
+ "1": {
660
+ "name": "keyword.control.tell.applescript"
661
+ }
662
+ },
663
+ "comment": "tell Finder",
664
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
665
+ "name": "meta.block.tell.application.finder.applescript",
666
+ "patterns": [
667
+ {
668
+ "include": "#finder"
669
+ },
670
+ {
671
+ "include": "#standard-suite"
672
+ },
673
+ {
674
+ "include": "$self"
675
+ }
676
+ ]
677
+ },
678
+ {
679
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\s+\"(?i:system events)\")(?!.*\\bto(?!\\s+tell)\\b)",
680
+ "captures": {
681
+ "1": {
682
+ "name": "keyword.control.tell.applescript"
683
+ }
684
+ },
685
+ "comment": "tell System Events",
686
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
687
+ "name": "meta.block.tell.application.system-events.applescript",
688
+ "patterns": [
689
+ {
690
+ "include": "#system-events"
691
+ },
692
+ {
693
+ "include": "#standard-suite"
694
+ },
695
+ {
696
+ "include": "$self"
697
+ }
698
+ ]
699
+ },
700
+ {
701
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\s+\"(?i:itunes)\")(?!.*\\bto(?!\\s+tell)\\b)",
702
+ "captures": {
703
+ "1": {
704
+ "name": "keyword.control.tell.applescript"
705
+ }
706
+ },
707
+ "comment": "tell iTunes",
708
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
709
+ "name": "meta.block.tell.application.itunes.applescript",
710
+ "patterns": [
711
+ {
712
+ "include": "#itunes"
713
+ },
714
+ {
715
+ "include": "#standard-suite"
716
+ },
717
+ {
718
+ "include": "$self"
719
+ }
720
+ ]
721
+ },
722
+ {
723
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\s+process\\b)(?!.*\\bto(?!\\s+tell)\\b)",
724
+ "captures": {
725
+ "1": {
726
+ "name": "keyword.control.tell.applescript"
727
+ }
728
+ },
729
+ "comment": "tell generic application process",
730
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
731
+ "name": "meta.block.tell.application-process.generic.applescript",
732
+ "patterns": [
733
+ {
734
+ "include": "#standard-suite"
735
+ },
736
+ {
737
+ "include": "$self"
738
+ }
739
+ ]
740
+ },
741
+ {
742
+ "begin": "^\\s*(tell)\\s+(?=app(lication)?\\b)(?!.*\\bto(?!\\s+tell)\\b)",
743
+ "captures": {
744
+ "1": {
745
+ "name": "keyword.control.tell.applescript"
746
+ }
747
+ },
748
+ "comment": "tell generic application",
749
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
750
+ "name": "meta.block.tell.application.generic.applescript",
751
+ "patterns": [
752
+ {
753
+ "include": "#standard-suite"
754
+ },
755
+ {
756
+ "include": "$self"
757
+ }
758
+ ]
759
+ },
760
+ {
761
+ "begin": "^\\s*(tell)\\s+(?!.*\\bto(?!\\s+tell)\\b)",
762
+ "captures": {
763
+ "1": {
764
+ "name": "keyword.control.tell.applescript"
765
+ }
766
+ },
767
+ "comment": "generic tell block",
768
+ "end": "^\\s*(end(?:\\s+tell)?)(?=\\s*(--.*?)?$)",
769
+ "name": "meta.block.tell.generic.applescript",
770
+ "patterns": [
771
+ {
772
+ "include": "$self"
773
+ }
774
+ ]
775
+ },
776
+ {
777
+ "begin": "^\\s*(tell)\\s+(?=.*\\bto\\b)",
778
+ "captures": {
779
+ "1": {
780
+ "name": "keyword.control.tell.applescript"
781
+ }
782
+ },
783
+ "comment": "tell … to statement",
784
+ "end": "(?<!¬)$",
785
+ "name": "meta.block.tell.generic.applescript",
786
+ "patterns": [
787
+ {
788
+ "include": "$self"
789
+ }
790
+ ]
791
+ }
792
+ ]
793
+ },
794
+ "built-in": {
795
+ "patterns": [
796
+ {
797
+ "include": "#built-in.constant"
798
+ },
799
+ {
800
+ "include": "#built-in.keyword"
801
+ },
802
+ {
803
+ "include": "#built-in.support"
804
+ },
805
+ {
806
+ "include": "#built-in.punctuation"
807
+ }
808
+ ]
809
+ },
810
+ "built-in.constant": {
811
+ "patterns": [
812
+ {
813
+ "comment": "yes/no can’t always be used as booleans, e.g. in an if() expression. But they work e.g. for boolean arguments.",
814
+ "match": "\\b(?i:true|false|yes|no)\\b",
815
+ "name": "constant.language.boolean.applescript"
816
+ },
817
+ {
818
+ "match": "\\b(?i:null|missing\\s+value)\\b",
819
+ "name": "constant.language.null.applescript"
820
+ },
821
+ {
822
+ "match": "-?\\b\\d+((\\.(\\d+\\b)?)?(?i:e\\+?\\d*\\b)?|\\b)",
823
+ "name": "constant.numeric.applescript"
824
+ },
825
+ {
826
+ "match": "\\b(?i:space|tab|return|linefeed|quote)\\b",
827
+ "name": "constant.other.text.applescript"
828
+ },
829
+ {
830
+ "match": "\\b(?i:all\\s+(caps|lowercase)|bold|condensed|expanded|hidden|italic|outline|plain|shadow|small\\s+caps|strikethrough|(sub|super)script|underline)\\b",
831
+ "name": "constant.other.styles.applescript"
832
+ },
833
+ {
834
+ "match": "\\b(?i:Jan(uary)?|Feb(ruary)?|Mar(ch)?|Apr(il)?|May|Jun(e)?|Jul(y)?|Aug(ust)?|Sep(tember)?|Oct(ober)?|Nov(ember)?|Dec(ember)?)\\b",
835
+ "name": "constant.other.time.month.applescript"
836
+ },
837
+ {
838
+ "match": "\\b(?i:Mon(day)?|Tue(sday)?|Wed(nesday)?|Thu(rsday)?|Fri(day)?|Sat(urday)?|Sun(day)?)\\b",
839
+ "name": "constant.other.time.weekday.applescript"
840
+ },
841
+ {
842
+ "match": "\\b(?i:AppleScript|pi|result|version|current\\s+application|its?|m[ey])\\b",
843
+ "name": "constant.other.miscellaneous.applescript"
844
+ },
845
+ {
846
+ "match": "\\b(?i:text\\s+item\\s+delimiters|print\\s+(length|depth))\\b",
847
+ "name": "variable.language.applescript"
848
+ }
849
+ ]
850
+ },
851
+ "built-in.keyword": {
852
+ "patterns": [
853
+ {
854
+ "match": "(&|\\*|\\+|-|/|÷|\\^)",
855
+ "name": "keyword.operator.arithmetic.applescript"
856
+ },
857
+ {
858
+ "match": "(=|≠|>|<|≥|>=|≤|<=)",
859
+ "name": "keyword.operator.comparison.applescript"
860
+ },
861
+ {
862
+ "match": "(?ix)\\b\n\t\t\t\t\t\t(and|or|div|mod|as|not\n\t\t\t\t\t\t|(a\\s+)?(ref(\\s+to)?|reference\\s+to)\n\t\t\t\t\t\t|equal(s|\\s+to)|contains?|comes\\s+(after|before)|(start|begin|end)s?\\s+with\n\t\t\t\t\t\t)\n\t\t\t\t\t\\b",
863
+ "name": "keyword.operator.word.applescript"
864
+ },
865
+ {
866
+ "comment": "In double quotes so we can use a single quote in the keywords.",
867
+ "match": "(?ix)\\b\n\t\t\t\t\t\t(is(n't|\\s+not)?(\\s+(equal(\\s+to)?|(less|greater)\\s+than(\\s+or\\s+equal(\\s+to)?)?|in|contained\\s+by))?\n\t\t\t\t\t\t|does(n't|\\s+not)\\s+(equal|come\\s+(before|after)|contain)\n\t\t\t\t\t\t)\n\t\t\t\t\t\\b",
868
+ "name": "keyword.operator.word.applescript"
869
+ },
870
+ {
871
+ "match": "\\b(?i:some|every|whose|where|that|id|index|\\d+(st|nd|rd|th)|first|second|third|fourth|fifth|sixth|seventh|eighth|ninth|tenth|last|front|back|middle|named|beginning|end|from|to|thr(u|ough)|before|(front|back|beginning|end)\\s+of|after|behind|in\\s+(front|back|beginning|end)\\s+of)\\b",
872
+ "name": "keyword.operator.reference.applescript"
873
+ },
874
+ {
875
+ "match": "\\b(?i:continue|return|exit(\\s+repeat)?)\\b",
876
+ "name": "keyword.control.loop.applescript"
877
+ },
878
+ {
879
+ "match": "\\b(?i:about|above|after|against|and|apart\\s+from|around|as|aside\\s+from|at|back|before|beginning|behind|below|beneath|beside|between|but|by|considering|contain|contains|contains|copy|div|does|eighth|else|end|equal|equals|error|every|false|fifth|first|for|fourth|from|front|get|given|global|if|ignoring|in|instead\\s+of|into|is|it|its|last|local|me|middle|mod|my|ninth|not|of|on|onto|or|out\\s+of|over|prop|property|put|ref|reference|repeat|returning|script|second|set|seventh|since|sixth|some|tell|tenth|that|the|then|third|through|thru|timeout|times|to|transaction|true|try|until|where|while|whose|with|without)\\b",
880
+ "name": "keyword.other.applescript"
881
+ }
882
+ ]
883
+ },
884
+ "built-in.punctuation": {
885
+ "patterns": [
886
+ {
887
+ "match": "¬",
888
+ "name": "punctuation.separator.continuation.line.applescript"
889
+ },
890
+ {
891
+ "comment": "the : in property assignments",
892
+ "match": ":",
893
+ "name": "punctuation.separator.key-value.property.applescript"
894
+ },
895
+ {
896
+ "comment": "the parentheses in groups",
897
+ "match": "[()]",
898
+ "name": "punctuation.section.group.applescript"
899
+ }
900
+ ]
901
+ },
902
+ "built-in.support": {
903
+ "patterns": [
904
+ {
905
+ "match": "\\b(?i:POSIX\\s+path|frontmost|id|name|running|version|days?|weekdays?|months?|years?|time|date\\s+string|time\\s+string|length|rest|reverse|items?|contents|quoted\\s+form|characters?|paragraphs?|words?)\\b",
906
+ "name": "support.function.built-in.property.applescript"
907
+ },
908
+ {
909
+ "match": "\\b(?i:activate|log|clipboard\\s+info|set\\s+the\\s+clipboard\\s+to|the\\s+clipboard|info\\s+for|list\\s+(disks|folder)|mount\\s+volume|path\\s+to(\\s+resource)?|close\\s+access|get\\s+eof|open\\s+for\\s+access|read|set\\s+eof|write|open\\s+location|current\\s+date|do\\s+shell\\s+script|get\\s+volume\\s+settings|random\\s+number|round|set\\s+volume|system\\s+(attribute|info)|time\\s+to\\s+GMT|load\\s+script|run\\s+script|scripting\\s+components|store\\s+script|copy|count|get|launch|run|set|ASCII\\s+(character|number)|localized\\s+string|offset|summarize|beep|choose\\s+(application|color|file(\\s+name)?|folder|from\\s+list|remote\\s+application|URL)|delay|display\\s+(alert|dialog)|say)\\b",
910
+ "name": "support.function.built-in.command.applescript"
911
+ },
912
+ {
913
+ "match": "\\b(?i:get|run)\\b",
914
+ "name": "support.function.built-in.applescript"
915
+ },
916
+ {
917
+ "match": "\\b(?i:anything|data|text|upper\\s+case|propert(y|ies))\\b",
918
+ "name": "support.class.built-in.applescript"
919
+ },
920
+ {
921
+ "match": "\\b(?i:alias|class)(es)?\\b",
922
+ "name": "support.class.built-in.applescript"
923
+ },
924
+ {
925
+ "match": "\\b(?i:app(lication)?|boolean|character|constant|date|event|file(\\s+specification)?|handler|integer|item|keystroke|linked\\s+list|list|machine|number|picture|preposition|POSIX\\s+file|real|record|reference(\\s+form)?|RGB\\s+color|script|sound|text\\s+item|type\\s+class|vector|writing\\s+code(\\s+info)?|zone|((international|styled(\\s+(Clipboard|Unicode))?|Unicode)\\s+)?text|((C|encoded|Pascal)\\s+)?string)s?\\b",
926
+ "name": "support.class.built-in.applescript"
927
+ },
928
+ {
929
+ "match": "(?ix)\\b\n\t\t\t\t\t\t(\t(cubic\\s+(centi)?|square\\s+(kilo)?|centi|kilo)met(er|re)s\n\t\t\t\t\t\t|\tsquare\\s+(yards|feet|miles)|cubic\\s+(yards|feet|inches)|miles|inches\n\t\t\t\t\t\t|\tlit(re|er)s|gallons|quarts\n\t\t\t\t\t\t|\t(kilo)?grams|ounces|pounds\n\t\t\t\t\t\t|\tdegrees\\s+(Celsius|Fahrenheit|Kelvin)\n\t\t\t\t\t\t)\n\t\t\t\t\t\\b",
930
+ "name": "support.class.built-in.unit.applescript"
931
+ },
932
+ {
933
+ "match": "\\b(?i:seconds|minutes|hours|days)\\b",
934
+ "name": "support.class.built-in.time.applescript"
935
+ }
936
+ ]
937
+ },
938
+ "comments": {
939
+ "patterns": [
940
+ {
941
+ "begin": "^\\s*(#!)",
942
+ "captures": {
943
+ "1": {
944
+ "name": "punctuation.definition.comment.applescript"
945
+ }
946
+ },
947
+ "end": "\\n",
948
+ "name": "comment.line.number-sign.applescript"
949
+ },
950
+ {
951
+ "begin": "(^[ \\t]+)?(?=--)",
952
+ "beginCaptures": {
953
+ "1": {
954
+ "name": "punctuation.whitespace.comment.leading.applescript"
955
+ }
956
+ },
957
+ "end": "(?!\\G)",
958
+ "patterns": [
959
+ {
960
+ "begin": "--",
961
+ "beginCaptures": {
962
+ "0": {
963
+ "name": "punctuation.definition.comment.applescript"
964
+ }
965
+ },
966
+ "end": "\\n",
967
+ "name": "comment.line.double-dash.applescript"
968
+ }
969
+ ]
970
+ },
971
+ {
972
+ "begin": "\\(\\*",
973
+ "captures": {
974
+ "0": {
975
+ "name": "punctuation.definition.comment.applescript"
976
+ }
977
+ },
978
+ "end": "\\*\\)",
979
+ "name": "comment.block.applescript",
980
+ "patterns": [
981
+ {
982
+ "include": "#comments.nested"
983
+ }
984
+ ]
985
+ }
986
+ ]
987
+ },
988
+ "comments.nested": {
989
+ "patterns": [
990
+ {
991
+ "begin": "\\(\\*",
992
+ "beginCaptures": {
993
+ "0": {
994
+ "name": "punctuation.definition.comment.begin.applescript"
995
+ }
996
+ },
997
+ "end": "\\*\\)",
998
+ "endCaptures": {
999
+ "0": {
1000
+ "name": "punctuation.definition.comment.end.applescript"
1001
+ }
1002
+ },
1003
+ "name": "comment.block.applescript",
1004
+ "patterns": [
1005
+ {
1006
+ "include": "#comments.nested"
1007
+ }
1008
+ ]
1009
+ }
1010
+ ]
1011
+ },
1012
+ "data-structures": {
1013
+ "patterns": [
1014
+ {
1015
+ "begin": "\\{",
1016
+ "beginCaptures": {
1017
+ "0": {
1018
+ "name": "punctuation.definition.array.begin.applescript"
1019
+ }
1020
+ },
1021
+ "comment": "We cannot necessarily distinguish \"records\" from \"arrays\", and so this could be either.",
1022
+ "end": "\\}",
1023
+ "endCaptures": {
1024
+ "0": {
1025
+ "name": "punctuation.definition.array.end.applescript"
1026
+ }
1027
+ },
1028
+ "name": "meta.array.applescript",
1029
+ "patterns": [
1030
+ {
1031
+ "captures": {
1032
+ "1": {
1033
+ "name": "constant.other.key.applescript"
1034
+ },
1035
+ "2": {
1036
+ "name": "meta.identifier.applescript"
1037
+ },
1038
+ "3": {
1039
+ "name": "punctuation.definition.identifier.applescript"
1040
+ },
1041
+ "4": {
1042
+ "name": "punctuation.definition.identifier.applescript"
1043
+ },
1044
+ "5": {
1045
+ "name": "punctuation.separator.key-value.applescript"
1046
+ }
1047
+ },
1048
+ "match": "(\\w+|((\\|)[^|\\n]*(\\|)))\\s*(:)"
1049
+ },
1050
+ {
1051
+ "match": ":",
1052
+ "name": "punctuation.separator.key-value.applescript"
1053
+ },
1054
+ {
1055
+ "match": ",",
1056
+ "name": "punctuation.separator.array.applescript"
1057
+ },
1058
+ {
1059
+ "include": "#inline"
1060
+ }
1061
+ ]
1062
+ },
1063
+ {
1064
+ "begin": "(?:(?<=application )|(?<=app ))(\")",
1065
+ "captures": {
1066
+ "1": {
1067
+ "name": "punctuation.definition.string.applescript"
1068
+ }
1069
+ },
1070
+ "end": "(\")",
1071
+ "name": "string.quoted.double.application-name.applescript",
1072
+ "patterns": [
1073
+ {
1074
+ "match": "\\\\.",
1075
+ "name": "constant.character.escape.applescript"
1076
+ }
1077
+ ]
1078
+ },
1079
+ {
1080
+ "begin": "(\")",
1081
+ "captures": {
1082
+ "1": {
1083
+ "name": "punctuation.definition.string.applescript"
1084
+ }
1085
+ },
1086
+ "end": "(\")",
1087
+ "name": "string.quoted.double.applescript",
1088
+ "patterns": [
1089
+ {
1090
+ "match": "\\\\.",
1091
+ "name": "constant.character.escape.applescript"
1092
+ }
1093
+ ]
1094
+ },
1095
+ {
1096
+ "captures": {
1097
+ "1": {
1098
+ "name": "punctuation.definition.identifier.applescript"
1099
+ },
1100
+ "2": {
1101
+ "name": "punctuation.definition.identifier.applescript"
1102
+ }
1103
+ },
1104
+ "match": "(\\|)[^|\\n]*(\\|)",
1105
+ "name": "meta.identifier.applescript"
1106
+ },
1107
+ {
1108
+ "captures": {
1109
+ "1": {
1110
+ "name": "punctuation.definition.data.applescript"
1111
+ },
1112
+ "2": {
1113
+ "name": "support.class.built-in.applescript"
1114
+ },
1115
+ "3": {
1116
+ "name": "storage.type.utxt.applescript"
1117
+ },
1118
+ "4": {
1119
+ "name": "string.unquoted.data.applescript"
1120
+ },
1121
+ "5": {
1122
+ "name": "punctuation.definition.data.applescript"
1123
+ },
1124
+ "6": {
1125
+ "name": "keyword.operator.applescript"
1126
+ },
1127
+ "7": {
1128
+ "name": "support.class.built-in.applescript"
1129
+ }
1130
+ },
1131
+ "match": "(«)(data) (utxt|utf8)([[:xdigit:]]*)(»)(?:\\s+(as)\\s+(?i:Unicode\\s+text))?",
1132
+ "name": "constant.other.data.utxt.applescript"
1133
+ },
1134
+ {
1135
+ "begin": "(«)(\\w+)\\b(?=\\s)",
1136
+ "beginCaptures": {
1137
+ "1": {
1138
+ "name": "punctuation.definition.data.applescript"
1139
+ },
1140
+ "2": {
1141
+ "name": "support.class.built-in.applescript"
1142
+ }
1143
+ },
1144
+ "end": "(»)",
1145
+ "endCaptures": {
1146
+ "1": {
1147
+ "name": "punctuation.definition.data.applescript"
1148
+ }
1149
+ },
1150
+ "name": "constant.other.data.raw.applescript"
1151
+ },
1152
+ {
1153
+ "captures": {
1154
+ "1": {
1155
+ "name": "punctuation.definition.data.applescript"
1156
+ },
1157
+ "2": {
1158
+ "name": "punctuation.definition.data.applescript"
1159
+ }
1160
+ },
1161
+ "match": "(«)[^»]*(»)",
1162
+ "name": "invalid.illegal.data.applescript"
1163
+ }
1164
+ ]
1165
+ },
1166
+ "finder": {
1167
+ "patterns": [
1168
+ {
1169
+ "match": "\\b(item|container|(computer|disk|trash)-object|disk|folder|((alias|application|document|internet location) )?file|clipping|package)s?\\b",
1170
+ "name": "support.class.finder.items.applescript"
1171
+ },
1172
+ {
1173
+ "match": "\\b((Finder|desktop|information|preferences|clipping) )windows?\\b",
1174
+ "name": "support.class.finder.window-classes.applescript"
1175
+ },
1176
+ {
1177
+ "match": "\\b(preferences|(icon|column|list) view options|(label|column|alias list)s?)\\b",
1178
+ "name": "support.class.finder.type-definitions.applescript"
1179
+ },
1180
+ {
1181
+ "match": "\\b(copy|find|sort|clean up|eject|empty( trash)|erase|reveal|update)\\b",
1182
+ "name": "support.function.finder.items.applescript"
1183
+ },
1184
+ {
1185
+ "match": "\\b(insertion location|product version|startup disk|desktop|trash|home|computer container|finder preferences)\\b",
1186
+ "name": "support.constant.finder.applescript"
1187
+ },
1188
+ {
1189
+ "match": "\\b(visible)\\b",
1190
+ "name": "support.variable.finder.applescript"
1191
+ }
1192
+ ]
1193
+ },
1194
+ "inline": {
1195
+ "patterns": [
1196
+ {
1197
+ "include": "#comments"
1198
+ },
1199
+ {
1200
+ "include": "#data-structures"
1201
+ },
1202
+ {
1203
+ "include": "#built-in"
1204
+ },
1205
+ {
1206
+ "include": "#standardadditions"
1207
+ }
1208
+ ]
1209
+ },
1210
+ "itunes": {
1211
+ "patterns": [
1212
+ {
1213
+ "match": "\\b(artwork|application|encoder|EQ preset|item|source|visual|(EQ |browser )?window|((audio CD|device|shared|URL|file) )?track|playlist window|((audio CD|device|radio tuner|library|folder|user) )?playlist)s?\\b",
1214
+ "name": "support.class.itunes.applescript"
1215
+ },
1216
+ {
1217
+ "match": "\\b(add|back track|convert|fast forward|(next|previous) track|pause|play(pause)?|refresh|resume|rewind|search|stop|update|eject|subscribe|update(Podcast|AllPodcasts)|download)\\b",
1218
+ "name": "support.function.itunes.applescript"
1219
+ },
1220
+ {
1221
+ "match": "\\b(current (playlist|stream (title|URL)|track)|player state)\\b",
1222
+ "name": "support.constant.itunes.applescript"
1223
+ },
1224
+ {
1225
+ "match": "\\b(current (encoder|EQ preset|visual)|EQ enabled|fixed indexing|full screen|mute|player position|sound volume|visuals enabled|visual size)\\b",
1226
+ "name": "support.variable.itunes.applescript"
1227
+ }
1228
+ ]
1229
+ },
1230
+ "standard-suite": {
1231
+ "patterns": [
1232
+ {
1233
+ "match": "\\b(colors?|documents?|items?|windows?)\\b",
1234
+ "name": "support.class.standard-suite.applescript"
1235
+ },
1236
+ {
1237
+ "match": "\\b(close|count|delete|duplicate|exists|make|move|open|print|quit|save|activate|select|data size)\\b",
1238
+ "name": "support.function.standard-suite.applescript"
1239
+ },
1240
+ {
1241
+ "match": "\\b(name|frontmost|version)\\b",
1242
+ "name": "support.constant.standard-suite.applescript"
1243
+ },
1244
+ {
1245
+ "match": "\\b(selection)\\b",
1246
+ "name": "support.variable.standard-suite.applescript"
1247
+ },
1248
+ {
1249
+ "match": "\\b(attachments?|attribute runs?|characters?|paragraphs?|texts?|words?)\\b",
1250
+ "name": "support.class.text-suite.applescript"
1251
+ }
1252
+ ]
1253
+ },
1254
+ "standardadditions": {
1255
+ "patterns": [
1256
+ {
1257
+ "match": "\\b((alert|dialog) reply)\\b",
1258
+ "name": "support.class.standardadditions.user-interaction.applescript"
1259
+ },
1260
+ {
1261
+ "match": "\\b(file information)\\b",
1262
+ "name": "support.class.standardadditions.file.applescript"
1263
+ },
1264
+ {
1265
+ "match": "\\b(POSIX files?|system information|volume settings)\\b",
1266
+ "name": "support.class.standardadditions.miscellaneous.applescript"
1267
+ },
1268
+ {
1269
+ "match": "\\b(URLs?|internet address(es)?|web pages?|FTP items?)\\b",
1270
+ "name": "support.class.standardadditions.internet.applescript"
1271
+ },
1272
+ {
1273
+ "match": "\\b(info for|list (disks|folder)|mount volume|path to( resource)?)\\b",
1274
+ "name": "support.function.standardadditions.file.applescript"
1275
+ },
1276
+ {
1277
+ "match": "\\b(beep|choose (application|color|file( name)?|folder|from list|remote application|URL)|delay|display (alert|dialog)|say)\\b",
1278
+ "name": "support.function.standardadditions.user-interaction.applescript"
1279
+ },
1280
+ {
1281
+ "match": "\\b(ASCII (character|number)|localized string|offset|summarize)\\b",
1282
+ "name": "support.function.standardadditions.string.applescript"
1283
+ },
1284
+ {
1285
+ "match": "\\b(set the clipboard to|the clipboard|clipboard info)\\b",
1286
+ "name": "support.function.standardadditions.clipboard.applescript"
1287
+ },
1288
+ {
1289
+ "match": "\\b(open for access|close access|read|write|get eof|set eof)\\b",
1290
+ "name": "support.function.standardadditions.file-i-o.applescript"
1291
+ },
1292
+ {
1293
+ "match": "\\b((load|store|run) script|scripting components)\\b",
1294
+ "name": "support.function.standardadditions.scripting.applescript"
1295
+ },
1296
+ {
1297
+ "match": "\\b(current date|do shell script|get volume settings|random number|round|set volume|system attribute|system info|time to GMT)\\b",
1298
+ "name": "support.function.standardadditions.miscellaneous.applescript"
1299
+ },
1300
+ {
1301
+ "match": "\\b(opening folder|(closing|moving) folder window for|adding folder items to|removing folder items from)\\b",
1302
+ "name": "support.function.standardadditions.folder-actions.applescript"
1303
+ },
1304
+ {
1305
+ "match": "\\b(open location|handle CGI request)\\b",
1306
+ "name": "support.function.standardadditions.internet.applescript"
1307
+ }
1308
+ ]
1309
+ },
1310
+ "system-events": {
1311
+ "patterns": [
1312
+ {
1313
+ "match": "\\b(audio (data|file))\\b",
1314
+ "name": "support.class.system-events.audio-file.applescript"
1315
+ },
1316
+ {
1317
+ "match": "\\b(alias(es)?|(Classic|local|network|system|user) domain objects?|disk( item)?s?|domains?|file( package)?s?|folders?|items?)\\b",
1318
+ "name": "support.class.system-events.disk-folder-file.applescript"
1319
+ },
1320
+ {
1321
+ "match": "\\b(delete|open|move)\\b",
1322
+ "name": "support.function.system-events.disk-folder-file.applescript"
1323
+ },
1324
+ {
1325
+ "match": "\\b(folder actions?|scripts?)\\b",
1326
+ "name": "support.class.system-events.folder-actions.applescript"
1327
+ },
1328
+ {
1329
+ "match": "\\b(attach action to|attached scripts|edit action of|remove action from)\\b",
1330
+ "name": "support.function.system-events.folder-actions.applescript"
1331
+ },
1332
+ {
1333
+ "match": "\\b(movie data|movie file)\\b",
1334
+ "name": "support.class.system-events.movie-file.applescript"
1335
+ },
1336
+ {
1337
+ "match": "\\b(log out|restart|shut down|sleep)\\b",
1338
+ "name": "support.function.system-events.power.applescript"
1339
+ },
1340
+ {
1341
+ "match": "\\b(((application |desk accessory )?process|(check|combo )?box)(es)?|(action|attribute|browser|(busy|progress|relevance) indicator|color well|column|drawer|group|grow area|image|incrementor|list|menu( bar)?( item)?|(menu |pop up |radio )?button|outline|(radio|tab|splitter) group|row|scroll (area|bar)|sheet|slider|splitter|static text|table|text (area|field)|tool bar|UI element|window)s?)\\b",
1342
+ "name": "support.class.system-events.processes.applescript"
1343
+ },
1344
+ {
1345
+ "match": "\\b(click|key code|keystroke|perform|select)\\b",
1346
+ "name": "support.function.system-events.processes.applescript"
1347
+ },
1348
+ {
1349
+ "match": "\\b(property list (file|item))\\b",
1350
+ "name": "support.class.system-events.property-list.applescript"
1351
+ },
1352
+ {
1353
+ "match": "\\b(annotation|QuickTime (data|file)|track)s?\\b",
1354
+ "name": "support.class.system-events.quicktime-file.applescript"
1355
+ },
1356
+ {
1357
+ "match": "\\b((abort|begin|end) transaction)\\b",
1358
+ "name": "support.function.system-events.system-events.applescript"
1359
+ },
1360
+ {
1361
+ "match": "\\b(XML (attribute|data|element|file)s?)\\b",
1362
+ "name": "support.class.system-events.xml.applescript"
1363
+ },
1364
+ {
1365
+ "match": "\\b(print settings|users?|login items?)\\b",
1366
+ "name": "support.class.sytem-events.other.applescript"
1367
+ }
1368
+ ]
1369
+ },
1370
+ "textmate": {
1371
+ "patterns": [
1372
+ {
1373
+ "match": "\\b(print settings)\\b",
1374
+ "name": "support.class.textmate.applescript"
1375
+ },
1376
+ {
1377
+ "match": "\\b(get url|insert|reload bundles)\\b",
1378
+ "name": "support.function.textmate.applescript"
1379
+ }
1380
+ ]
1381
+ }
1382
+ },
1383
+ "scopeName": "source.applescript",
1384
+ "uuid": "777CF925-14B9-428E-B07B-17FAAB8FA27E"
1385
+ }