tm-grammars 1.6.9 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,233 @@
1
+ {
2
+ "displayName": "Fennel",
3
+ "name": "fennel",
4
+ "patterns": [
5
+ {
6
+ "include": "#expression"
7
+ }
8
+ ],
9
+ "repository": {
10
+ "comment": {
11
+ "patterns": [
12
+ {
13
+ "begin": ";",
14
+ "end": "$",
15
+ "name": "comment.line.semicolon.fennel"
16
+ }
17
+ ]
18
+ },
19
+ "constants": {
20
+ "patterns": [
21
+ {
22
+ "match": "nil",
23
+ "name": "constant.language.nil.fennel"
24
+ },
25
+ {
26
+ "match": "false|true",
27
+ "name": "constant.language.boolean.fennel"
28
+ },
29
+ {
30
+ "match": "(-?\\d+\\.\\d+([eE][+-]?\\d+)?)",
31
+ "name": "constant.numeric.double.fennel"
32
+ },
33
+ {
34
+ "match": "(-?\\d+)",
35
+ "name": "constant.numeric.integer.fennel"
36
+ }
37
+ ]
38
+ },
39
+ "expression": {
40
+ "patterns": [
41
+ {
42
+ "include": "#comment"
43
+ },
44
+ {
45
+ "include": "#constants"
46
+ },
47
+ {
48
+ "include": "#sexp"
49
+ },
50
+ {
51
+ "include": "#table"
52
+ },
53
+ {
54
+ "include": "#vector"
55
+ },
56
+ {
57
+ "include": "#keywords"
58
+ },
59
+ {
60
+ "include": "#special"
61
+ },
62
+ {
63
+ "include": "#lua"
64
+ },
65
+ {
66
+ "include": "#strings"
67
+ },
68
+ {
69
+ "include": "#methods"
70
+ },
71
+ {
72
+ "include": "#symbols"
73
+ }
74
+ ]
75
+ },
76
+ "keywords": {
77
+ "match": ":[^ ]+",
78
+ "name": "constant.keyword.fennel"
79
+ },
80
+ "lua": {
81
+ "patterns": [
82
+ {
83
+ "match": "\\b(assert|collectgarbage|dofile|error|getmetatable|ipairs|load|loadfile|next|pairs|pcall|print|rawequal|rawget|rawlen|rawset|require|select|setmetatable|tonumber|tostring|type|xpcall)\\b",
84
+ "name": "support.function.fennel"
85
+ },
86
+ {
87
+ "match": "\\b(coroutine|coroutine.create|coroutine.isyieldable|coroutine.resume|coroutine.running|coroutine.status|coroutine.wrap|coroutine.yield|debug|debug.debug|debug.gethook|debug.getinfo|debug.getlocal|debug.getmetatable|debug.getregistry|debug.getupvalue|debug.getuservalue|debug.sethook|debug.setlocal|debug.setmetatable|debug.setupvalue|debug.setuservalue|debug.traceback|debug.upvalueid|debug.upvaluejoin|io|io.close|io.flush|io.input|io.lines|io.open|io.output|io.popen|io.read|io.stderr|io.stdin|io.stdout|io.tmpfile|io.type|io.write|math|math.abs|math.acos|math.asin|math.atan|math.ceil|math.cos|math.deg|math.exp|math.floor|math.fmod|math.huge|math.log|math.max|math.maxinteger|math.min|math.mininteger|math.modf|math.pi|math.rad|math.random|math.randomseed|math.sin|math.sqrt|math.tan|math.tointeger|math.type|math.ult|os|os.clock|os.date|os.difftime|os.execute|os.exit|os.getenv|os.remove|os.rename|os.setlocale|os.time|os.tmpname|package|package.config|package.cpath|package.loaded|package.loadlib|package.path|package.preload|package.searchers|package.searchpath|string|string.byte|string.char|string.dump|string.find|string.format|string.gmatch|string.gsub|string.len|string.lower|string.match|string.pack|string.packsize|string.rep|string.reverse|string.sub|string.unpack|string.upper|table|table.concat|table.insert|table.move|table.pack|table.remove|table.sort|table.unpack|utf8|utf8.char|utf8.charpattern|utf8.codepoint|utf8.codes|utf8.len|utf8.offset)\\b",
88
+ "name": "support.function.library.fennel"
89
+ },
90
+ {
91
+ "match": "\\b(_G|_VERSION)\\b",
92
+ "name": "constant.language.fennel"
93
+ }
94
+ ]
95
+ },
96
+ "methods": {
97
+ "patterns": [
98
+ {
99
+ "match": "\\w+\\:\\w+",
100
+ "name": "entity.name.function.method.fennel"
101
+ }
102
+ ]
103
+ },
104
+ "sexp": {
105
+ "begin": "\\(",
106
+ "beginCaptures": {
107
+ "0": {
108
+ "name": "punctuation.paren.open.fennel"
109
+ }
110
+ },
111
+ "end": "\\)",
112
+ "endCaptures": {
113
+ "0": {
114
+ "name": "punctuation.paren.close.fennel"
115
+ }
116
+ },
117
+ "name": "sexp.fennel",
118
+ "patterns": [
119
+ {
120
+ "include": "#expression"
121
+ }
122
+ ]
123
+ },
124
+ "special": {
125
+ "patterns": [
126
+ {
127
+ "match": "\\#|\\%|\\+|\\*|[?][.]|(\\.)?\\.|(\\/)?\\/|:|<=?|=|>=?|\\^",
128
+ "name": "keyword.special.fennel"
129
+ },
130
+ {
131
+ "match": "(\\-\\>(\\>)?)",
132
+ "name": "keyword.special.fennel"
133
+ },
134
+ {
135
+ "match": "\\-\\?\\>(\\>)?",
136
+ "name": "keyword.special.fennel"
137
+ },
138
+ {
139
+ "match": "-",
140
+ "name": "keyword.special.fennel"
141
+ },
142
+ {
143
+ "match": "not=",
144
+ "name": "keyword.special.fennel"
145
+ },
146
+ {
147
+ "match": "set-forcibly!",
148
+ "name": "keyword.special.fennel"
149
+ },
150
+ {
151
+ "match": "\\b(and|band|bnot|bor|bxor|collect|comment|do|doc|doto|each|eval-compiler|for|global|hashfn|icollect|if|import-macros|include|lambda|length|let|local|lshift|lua|macro|macrodebug|macros|match|not=?|or|partial|pick-args|pick-values|quote|require-macros|rshift|set|tset|values|var|when|while|with-open)\\b",
152
+ "name": "keyword.special.fennel"
153
+ },
154
+ {
155
+ "match": "\\b(fn)\\b",
156
+ "name": "keyword.control.fennel"
157
+ },
158
+ {
159
+ "match": "~=",
160
+ "name": "keyword.special.fennel"
161
+ },
162
+ {
163
+ "match": "λ",
164
+ "name": "keyword.special.fennel"
165
+ }
166
+ ]
167
+ },
168
+ "strings": {
169
+ "begin": "\"",
170
+ "end": "\"",
171
+ "name": "string.quoted.double.fennel",
172
+ "patterns": [
173
+ {
174
+ "match": "\\\\.",
175
+ "name": "constant.character.escape.fennel"
176
+ }
177
+ ]
178
+ },
179
+ "symbols": {
180
+ "patterns": [
181
+ {
182
+ "match": "\\w+(?:\\.\\w+)+",
183
+ "name": "entity.name.function.symbol.fennel"
184
+ },
185
+ {
186
+ "match": "\\w+",
187
+ "name": "variable.other.fennel"
188
+ }
189
+ ]
190
+ },
191
+ "table": {
192
+ "begin": "\\{",
193
+ "beginCaptures": {
194
+ "0": {
195
+ "name": "punctuation.table.bracket.open.fennel"
196
+ }
197
+ },
198
+ "end": "\\}",
199
+ "endCaptures": {
200
+ "0": {
201
+ "name": "punctuation.table.bracket.close.fennel"
202
+ }
203
+ },
204
+ "name": "table.fennel",
205
+ "patterns": [
206
+ {
207
+ "include": "#expression"
208
+ }
209
+ ]
210
+ },
211
+ "vector": {
212
+ "begin": "\\[",
213
+ "beginCaptures": {
214
+ "0": {
215
+ "name": "punctuation.vector.bracket.open.fennel"
216
+ }
217
+ },
218
+ "end": "\\]",
219
+ "endCaptures": {
220
+ "0": {
221
+ "name": "punctuation.vector.bracket.close.fennel"
222
+ }
223
+ },
224
+ "name": "meta.vector.fennel",
225
+ "patterns": [
226
+ {
227
+ "include": "#expression"
228
+ }
229
+ ]
230
+ }
231
+ },
232
+ "scopeName": "source.fnl"
233
+ }
@@ -0,0 +1,88 @@
1
+ {
2
+ "displayName": "Hy",
3
+ "name": "hy",
4
+ "patterns": [
5
+ {
6
+ "include": "#all"
7
+ }
8
+ ],
9
+ "repository": {
10
+ "all": {
11
+ "patterns": [
12
+ {
13
+ "include": "#comment"
14
+ },
15
+ {
16
+ "include": "#constants"
17
+ },
18
+ {
19
+ "include": "#keywords"
20
+ },
21
+ {
22
+ "include": "#strings"
23
+ },
24
+ {
25
+ "include": "#operators"
26
+ },
27
+ {
28
+ "include": "#keysym"
29
+ },
30
+ {
31
+ "include": "#symbol"
32
+ }
33
+ ]
34
+ },
35
+ "comment": {
36
+ "patterns": [
37
+ {
38
+ "match": "(;).*$",
39
+ "name": "comment.line.hy"
40
+ }
41
+ ]
42
+ },
43
+ "constants": {
44
+ "patterns": [
45
+ {
46
+ "match": "(?<=[\\{\\[\\(\\s])([0-9]+(\\.[0-9]+)?|(#x)[0-9a-fA-F]+|(#o)[0-7]+|(#b)[01]+)(?=[\\s;()'\",\\[\\]\\{\\}])",
47
+ "name": "constant.numeric.hy"
48
+ }
49
+ ]
50
+ },
51
+ "keysym": {
52
+ "match": "(?<![\\.:\\w_\\-=!@\\$%^&?\\/<>*]):[\\.:\\w_\\-=!@\\$%^&?\\/<>*]*",
53
+ "name": "variable.other.constant"
54
+ },
55
+ "keywords": {
56
+ "patterns": [
57
+ {
58
+ "match": "\\b(\\.|->|->>|and|match|let|await|annotate|as->|as-model|assert|assoc|break|chainc|comment|cond|continue|do|doc|#doc|([dgls])?for|set[vx]|defclass|defmain|defmacro|defmacro\\/g!|defmacro!|deftag|del|doto|eval-and-compile|eval-when-compile|first|gensym|get|global|if|if\\*|if-not|import|(de)?fn(\\/a)?|last|nonlocal|not(\\?|-in)?|or|print|(quasi)?quote|require|rest|return|cut|raise|try|unless|unpack-iterable|unpack-mapping|unquote|unquote-splice|when|while|with(\\/a)?|with-decorator|with-gensyms|xor|yield(-from)?|butlast|coll\\?|comp|complement|constantly|dec|disassemble|empty\\?|eval|every\\?|exec|float\\?|fraction|even\\?|identity|inc|instance\\?|integer\\?|interleave|interpose|iterable\\?|iterator\\?|juxt|keyword|keyword\\?|macroexpand(-1)?|mangle|merge-with|name|neg\\?|none\\?|nth|numeric\\?|odd\\?|partition|pos\\?|second|some|string\\?|symbol\\?|zero\\?|cycle|distinct|drop|drop-last|drop-while|filter|flatten|iterate|read|read-str|remove|repeat|repeatedly|take|take-nth|take-while|unmangle|False|None|True|as|in|is|py(s)?|lambda|nonlocal|not|pass|abs|all|any|ascii|bin|bool|bytearray|bytes|callable|chr|classmethod|compile|complex|delattr|dict|dir|divmod|enumerate|eval|exec|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|isinstance|issubclass|iter|len|list|locals|map|max|memoryview|min|next|object|oct|open|ord|pow|print|property|range|repr(-register)?|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|vars|zip|__import__|abs|acos|angle|asin|assoc|assq|assv|atan|ceiling|cos|floor|round|sin|sqrt|tan|(?:real|imag)-part|numerator|denominatormodulo|exp|expt|remainder|quotient|lcm|call-with-(?:input|output)-file|(?:close|current)-(?:input|output)-port|with-(?:input|output)-from-file|open-(?:input|output)-file|char-(?:downcase|upcase|ready)|make-(?:polar|promise|rectangular|string|vector)|string(?:-(?:append|copy|length|ref))|vector(?:-length|-ref))[\\s\\)]",
59
+ "name": "keyword.control.hy"
60
+ }
61
+ ]
62
+ },
63
+ "operators": {
64
+ "patterns": [
65
+ {
66
+ "match": "(?<=\\()\\s*(\\+=?|\\/+|\\*+|-=?|[!<>]?=|@|%|<<|>>|<|>|&|\\||\\^|~)",
67
+ "name": "keyword.control.hy"
68
+ }
69
+ ]
70
+ },
71
+ "strings": {
72
+ "begin": "(f?\"|}(?=[^\n]*?[{\"]))",
73
+ "end": "(\"|(?<=[\"}][^\n]*?){)",
74
+ "name": "string.quoted.double.hy",
75
+ "patterns": [
76
+ {
77
+ "match": "\\\\.",
78
+ "name": "constant.character.escape.hy"
79
+ }
80
+ ]
81
+ },
82
+ "symbol": {
83
+ "match": "(?<![\\.:\\w_\\-=!@\\$%^&?/<>*#])[\\.a-zA-ZΑ-Ωα-ω_\\-=!@\\$%^<?/<>*#][\\.:\\w_\\-=!@\\$%^&?/<>*#]*",
84
+ "name": "variable.other.hy"
85
+ }
86
+ },
87
+ "scopeName": "source.hy"
88
+ }
@@ -0,0 +1,127 @@
1
+ {
2
+ "displayName": "Log file",
3
+ "fileTypes": [
4
+ "log"
5
+ ],
6
+ "name": "log",
7
+ "patterns": [
8
+ {
9
+ "match": "\\b(Trace)\\b:",
10
+ "name": "comment log.verbose"
11
+ },
12
+ {
13
+ "match": "(?i)\\[(verbose|verb|vrb|vb|v)\\]",
14
+ "name": "comment log.verbose"
15
+ },
16
+ {
17
+ "match": "(?<=^[\\s\\d\\p]*)\\bV\\b",
18
+ "name": "comment log.verbose"
19
+ },
20
+ {
21
+ "match": "\\b(DEBUG|Debug)\\b|(?i)\\b(debug)\\:",
22
+ "name": "markup.changed log.debug"
23
+ },
24
+ {
25
+ "match": "(?i)\\[(debug|dbug|dbg|de|d)\\]",
26
+ "name": "markup.changed log.debug"
27
+ },
28
+ {
29
+ "match": "(?<=^[\\s\\d\\p]*)\\bD\\b",
30
+ "name": "markup.changed log.debug"
31
+ },
32
+ {
33
+ "match": "\\b(HINT|INFO|INFORMATION|Info|NOTICE|II)\\b|(?i)\\b(info|information)\\:",
34
+ "name": "markup.inserted log.info"
35
+ },
36
+ {
37
+ "match": "(?i)\\[(information|info|inf|in|i)\\]",
38
+ "name": "markup.inserted log.info"
39
+ },
40
+ {
41
+ "match": "(?<=^[\\s\\d\\p]*)\\bI\\b",
42
+ "name": "markup.inserted log.info"
43
+ },
44
+ {
45
+ "match": "\\b(WARNING|WARN|Warn|WW)\\b|(?i)\\b(warning)\\:",
46
+ "name": "markup.deleted log.warning"
47
+ },
48
+ {
49
+ "match": "(?i)\\[(warning|warn|wrn|wn|w)\\]",
50
+ "name": "markup.deleted log.warning"
51
+ },
52
+ {
53
+ "match": "(?<=^[\\s\\d\\p]*)\\bW\\b",
54
+ "name": "markup.deleted log.warning"
55
+ },
56
+ {
57
+ "match": "\\b(ALERT|CRITICAL|EMERGENCY|ERROR|FAILURE|FAIL|Fatal|FATAL|Error|EE)\\b|(?i)\\b(error)\\:",
58
+ "name": "string.regexp, strong log.error"
59
+ },
60
+ {
61
+ "match": "(?i)\\[(error|eror|err|er|e|fatal|fatl|ftl|fa|f)\\]",
62
+ "name": "string.regexp, strong log.error"
63
+ },
64
+ {
65
+ "match": "(?<=^[\\s\\d\\p]*)\\bE\\b",
66
+ "name": "string.regexp, strong log.error"
67
+ },
68
+ {
69
+ "match": "\\b\\d{4}-\\d{2}-\\d{2}(T|\\b)",
70
+ "name": "comment log.date"
71
+ },
72
+ {
73
+ "match": "(?<=(^|\\s))\\d{2}[^\\w\\s]\\d{2}[^\\w\\s]\\d{4}\\b",
74
+ "name": "comment log.date"
75
+ },
76
+ {
77
+ "match": "\\d{1,2}:\\d{2}(:\\d{2}([.,]\\d{1,})?)?(Z| ?[+-]\\d{1,2}:\\d{2})?\\b",
78
+ "name": "comment log.date"
79
+ },
80
+ {
81
+ "match": "\\b([0-9a-fA-F]{40}|[0-9a-fA-F]{10}|[0-9a-fA-F]{7})\\b",
82
+ "name": "constant.language"
83
+ },
84
+ {
85
+ "match": "\\b[0-9a-fA-F]{8}[-]?([0-9a-fA-F]{4}[-]?){3}[0-9a-fA-F]{12}\\b",
86
+ "name": "constant.language log.constant"
87
+ },
88
+ {
89
+ "match": "\\b([0-9a-fA-F]{2,}[:-])+[0-9a-fA-F]{2,}+\\b",
90
+ "name": "constant.language log.constant"
91
+ },
92
+ {
93
+ "match": "\\b([0-9]+|true|false|null)\\b",
94
+ "name": "constant.language log.constant"
95
+ },
96
+ {
97
+ "match": "\\b(0x[a-fA-F0-9]+)\\b",
98
+ "name": "constant.language log.constant"
99
+ },
100
+ {
101
+ "match": "\"[^\"]*\"",
102
+ "name": "string log.string"
103
+ },
104
+ {
105
+ "match": "(?<![\\w])'[^']*'",
106
+ "name": "string log.string"
107
+ },
108
+ {
109
+ "match": "\\b([a-zA-Z.]*Exception)\\b",
110
+ "name": "string.regexp, emphasis log.exceptiontype"
111
+ },
112
+ {
113
+ "begin": "^[\\t ]*at[\\t ]",
114
+ "end": "$",
115
+ "name": "string.key, emphasis log.exception"
116
+ },
117
+ {
118
+ "match": "\\b[a-z]+://\\S+\\b/?",
119
+ "name": "constant.language log.constant"
120
+ },
121
+ {
122
+ "match": "(?<![\\w/\\\\])([\\w-]+\\.)+([\\w-])+(?![\\w/\\\\])",
123
+ "name": "constant.language log.constant"
124
+ }
125
+ ],
126
+ "scopeName": "text.log"
127
+ }