chamba 0.7.0 → 0.9.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.
- package/LICENSE +53 -14
- package/README.md +34 -8
- package/dist/commands/advanced.js +7 -278
- package/dist/commands/dev.js +11 -612
- package/dist/commands/doctor.js +1 -29
- package/dist/commands/menu.js +1 -80
- package/dist/commands/onboard.js +6 -230
- package/dist/commands/settings.js +15 -349
- package/dist/lib/agent-commands.js +2 -0
- package/dist/lib/agent-context.js +6 -210
- package/dist/lib/browser.js +1 -40
- package/dist/lib/chamba-yaml.js +10 -191
- package/dist/lib/constants.js +1 -125
- package/dist/lib/dockerfile-builder.js +41 -261
- package/dist/lib/env.js +2 -78
- package/dist/lib/git-env.js +1 -21
- package/dist/lib/global-config.js +4 -66
- package/dist/lib/pnpm-store.js +1 -19
- package/dist/lib/ports.js +1 -210
- package/dist/lib/safe-rm.js +1 -36
- package/dist/lib/sessions.js +2 -34
- package/dist/lib/shadows.js +1 -176
- package/dist/lib/skills.js +2 -0
- package/dist/lib/templates.js +1 -0
- package/dist/lib/webterm.js +1 -305
- package/dist/lib/workspace-identity.js +4 -260
- package/package.json +4 -4
- package/templates/Dockerfile +15 -22
- package/templates/claude-statusline.sh +5 -7
- package/templates/context/baseline.md +4 -2
- package/templates/context/web-pane-craft.md +1 -1
- package/templates/pane-apps/client/assets/api-BBDf_rzz.js +12 -0
- package/templates/pane-apps/client/assets/api-DNLbSBpK.css +1 -0
- package/templates/pane-apps/client/assets/bee-B7t97l5B.webp +0 -0
- package/templates/pane-apps/client/assets/buzz-CUUsbnXH.mp3 +0 -0
- package/templates/pane-apps/client/assets/c-BNa-DeUl.json +3552 -0
- package/templates/pane-apps/client/assets/cpp-B-T4NRoH.json +20239 -0
- package/templates/pane-apps/client/assets/csharp-BbxHChhA.json +6010 -0
- package/templates/pane-apps/client/assets/css-CWCxuwmz.json +1860 -0
- package/templates/pane-apps/client/assets/diff-B-2N89g8.json +154 -0
- package/templates/pane-apps/client/assets/docker-DWTvYW26.json +103 -0
- package/templates/pane-apps/client/assets/files-BkmyervY.js +1 -0
- package/templates/pane-apps/client/assets/go-B2hyYeNg.json +3156 -0
- package/templates/pane-apps/client/assets/graphql-Z6Id2aNO.json +1292 -0
- package/templates/pane-apps/client/assets/home-3SeGzySM.css +1 -0
- package/templates/pane-apps/client/assets/home-Cu9xOd2i.js +1 -0
- package/templates/pane-apps/client/assets/html-BtzvlIfu.json +2627 -0
- package/templates/pane-apps/client/assets/ini-Bn3Twap1.json +108 -0
- package/templates/pane-apps/client/assets/java-C7t2dwLO.json +1885 -0
- package/templates/pane-apps/client/assets/javascript-DuC2v0C0.json +5996 -0
- package/templates/pane-apps/client/assets/json-CwdkWeV5.json +206 -0
- package/templates/pane-apps/client/assets/jsonc-MYWDbTU3.json +206 -0
- package/templates/pane-apps/client/assets/jsx-Cn8EZuIC.json +5996 -0
- package/templates/pane-apps/client/assets/kotlin-CFNOz1gw.json +580 -0
- package/templates/pane-apps/client/assets/make-BVnlFCcl.json +629 -0
- package/templates/pane-apps/client/assets/markdown-B4Xk2WM_.json +3263 -0
- package/templates/pane-apps/client/assets/php-CAQzQmmI.json +4188 -0
- package/templates/pane-apps/client/assets/pop-D5ZANBC3.mp3 +0 -0
- package/templates/pane-apps/client/assets/python-CYQee8m4.json +4174 -0
- package/templates/pane-apps/client/assets/reviews-DMrGB-kG.js +153 -0
- package/templates/pane-apps/client/assets/reviews-nK_yRav9.css +1 -0
- package/templates/pane-apps/client/assets/ruby-D7R58tus.json +3114 -0
- package/templates/pane-apps/client/assets/rust-BFBbFiei.json +1103 -0
- package/templates/pane-apps/client/assets/scss-TQRhBkPG.json +1874 -0
- package/templates/pane-apps/client/assets/shellscript-DieAkC4W.json +2375 -0
- package/templates/pane-apps/client/assets/specs-Cabb15F0.js +13 -0
- package/templates/pane-apps/client/assets/sql-Bxd030LV.json +634 -0
- package/templates/pane-apps/client/assets/toml-ChrKGzsV.json +430 -0
- package/templates/pane-apps/client/assets/tsx-D2e90MFw.json +5996 -0
- package/templates/pane-apps/client/assets/typescript-DonXQ_n1.json +5747 -0
- package/templates/pane-apps/client/assets/useNow-BHFKFraS.js +1 -0
- package/templates/pane-apps/client/assets/xml-B17r2RXF.json +382 -0
- package/templates/pane-apps/client/assets/yaml-CKn4h1zy.json +627 -0
- package/templates/pane-apps/client/home/index.html +16 -0
- package/templates/pane-apps/client/reviews/index.html +17 -0
- package/templates/pane-apps/client/specs/index.html +4 -2
- package/templates/pane-apps/server/home.mjs +12 -0
- package/templates/pane-apps/server/reviews.mjs +21 -0
- package/templates/pane-apps/server/specs.mjs +5 -1588
- package/templates/skills/chamba-statusline/SKILL.md +7 -19
- package/templates/skills/dx-review/SKILL.md +136 -0
- package/templates/skills/dx-review/references/acts.md +233 -0
- package/templates/skills/dx-spec/SKILL.md +230 -30
- package/templates/skills/dx-spec/references/principles-template.md +2 -0
- package/templates/skills/dx-spec/references/review-guide.md +6 -52
- package/templates/skills/dx-spec/references/spec-guide.md +25 -5
- package/templates/skills/dx-spec/references/stages.md +149 -60
- package/templates/skills/dx-spec-execute/SKILL.md +217 -38
- package/templates/startup.mjs +22 -16
- package/templates/tool-helper.sh +168 -0
- package/templates/webterm/README.md +82 -27
- package/templates/webterm/color.js +61 -0
- package/templates/webterm/config.js +55 -4
- package/templates/webterm/context/claude.md +0 -1
- package/templates/webterm/public/app/alerts.js +95 -14
- package/templates/webterm/public/app/anchored.js +81 -0
- package/templates/webterm/public/app/composer.js +37 -3
- package/templates/webterm/public/app/connection.js +23 -0
- package/templates/webterm/public/app/dom.js +3 -0
- package/templates/webterm/public/app/frames.js +52 -18
- package/templates/webterm/public/app/home-host.js +16 -0
- package/templates/webterm/public/app/main.js +24 -8
- package/templates/webterm/public/app/new-session.js +13 -41
- package/templates/webterm/public/app/palette.js +58 -0
- package/templates/webterm/public/app/pane-shape.js +169 -0
- package/templates/webterm/public/app/pane-shell.js +240 -135
- package/templates/webterm/public/app/pane.js +39 -24
- package/templates/webterm/public/app/reviews-host.js +19 -0
- package/templates/webterm/public/app/specs-host.js +12 -218
- package/templates/webterm/public/app/state.js +5 -0
- package/templates/webterm/public/app/tabs.js +6 -2
- package/templates/webterm/public/app/theme.js +75 -27
- package/templates/webterm/public/app/tool-host.js +318 -0
- package/templates/webterm/public/app/workspace-color.js +192 -0
- package/templates/webterm/public/index.html +22 -4
- package/templates/webterm/public/styles.css +195 -21
- package/templates/webterm/server.js +198 -150
- package/templates/webterm/tool-document.js +3 -2
- package/templates/webterm/tools/commands.js +61 -0
- package/templates/webterm/tools/home.js +58 -0
- package/templates/webterm/tools/index.js +26 -0
- package/templates/webterm/tools/mount.js +337 -0
- package/templates/webterm/tools/paths.js +34 -0
- package/templates/webterm/tools/reviews.js +137 -0
- package/templates/webterm/tools/specs.js +154 -0
- package/templates/webterm/typed-line.js +70 -7
- package/templates/context/context-usage.md +0 -1
- package/templates/context-usage.sh +0 -266
- package/templates/pane-apps/client/assets/specs-B1970L17.css +0 -1
- package/templates/pane-apps/client/assets/specs-cEee_SPn.js +0 -23
- package/templates/skills/dx-spec-config/SKILL.md +0 -313
- package/templates/skills/dx-spec-config/references/principles-template.md +0 -12
- package/templates/specs.sh +0 -106
- package/templates/webterm/specs.js +0 -358
|
@@ -0,0 +1,580 @@
|
|
|
1
|
+
{
|
|
2
|
+
"displayName": "Kotlin",
|
|
3
|
+
"fileTypes": [
|
|
4
|
+
"kt",
|
|
5
|
+
"kts"
|
|
6
|
+
],
|
|
7
|
+
"name": "kotlin",
|
|
8
|
+
"patterns": [
|
|
9
|
+
{
|
|
10
|
+
"include": "#import"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
"include": "#package"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"include": "#code"
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
"repository": {
|
|
20
|
+
"annotation-simple": {
|
|
21
|
+
"match": "(?<!\\w)@[.\\w]+\\b(?!:)",
|
|
22
|
+
"name": "entity.name.type.annotation.kotlin"
|
|
23
|
+
},
|
|
24
|
+
"annotation-site": {
|
|
25
|
+
"begin": "(?<!\\w)(@\\w+):\\s*(?!\\[)",
|
|
26
|
+
"beginCaptures": {
|
|
27
|
+
"1": {
|
|
28
|
+
"name": "entity.name.type.annotation-site.kotlin"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"end": "$",
|
|
32
|
+
"patterns": [
|
|
33
|
+
{
|
|
34
|
+
"include": "#unescaped-annotation"
|
|
35
|
+
}
|
|
36
|
+
]
|
|
37
|
+
},
|
|
38
|
+
"annotation-site-list": {
|
|
39
|
+
"begin": "(?<!\\w)(@\\w+):\\s*\\[",
|
|
40
|
+
"beginCaptures": {
|
|
41
|
+
"1": {
|
|
42
|
+
"name": "entity.name.type.annotation-site.kotlin"
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
"end": "]",
|
|
46
|
+
"patterns": [
|
|
47
|
+
{
|
|
48
|
+
"include": "#unescaped-annotation"
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
},
|
|
52
|
+
"binary-literal": {
|
|
53
|
+
"match": "0([Bb])[01][01_]*",
|
|
54
|
+
"name": "constant.numeric.binary.kotlin"
|
|
55
|
+
},
|
|
56
|
+
"boolean-literal": {
|
|
57
|
+
"match": "\\b(true|false)\\b",
|
|
58
|
+
"name": "constant.language.boolean.kotlin"
|
|
59
|
+
},
|
|
60
|
+
"character": {
|
|
61
|
+
"begin": "'",
|
|
62
|
+
"end": "'",
|
|
63
|
+
"name": "string.quoted.single.kotlin",
|
|
64
|
+
"patterns": [
|
|
65
|
+
{
|
|
66
|
+
"match": "\\\\.",
|
|
67
|
+
"name": "constant.character.escape.kotlin"
|
|
68
|
+
}
|
|
69
|
+
]
|
|
70
|
+
},
|
|
71
|
+
"class-declaration": {
|
|
72
|
+
"captures": {
|
|
73
|
+
"1": {
|
|
74
|
+
"name": "keyword.hard.class.kotlin"
|
|
75
|
+
},
|
|
76
|
+
"2": {
|
|
77
|
+
"name": "entity.name.type.class.kotlin"
|
|
78
|
+
},
|
|
79
|
+
"3": {
|
|
80
|
+
"patterns": [
|
|
81
|
+
{
|
|
82
|
+
"include": "#type-parameter"
|
|
83
|
+
}
|
|
84
|
+
]
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"match": "\\b(class|(?:fun\\s+)?interface)\\s+(\\b\\w+\\b|`[^`]+`)\\s*(?<GROUP><([^<>]|\\g<GROUP>)+>)?"
|
|
88
|
+
},
|
|
89
|
+
"code": {
|
|
90
|
+
"patterns": [
|
|
91
|
+
{
|
|
92
|
+
"include": "#comments"
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"include": "#keywords"
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"include": "#annotation-simple"
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"include": "#annotation-site-list"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"include": "#annotation-site"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"include": "#class-declaration"
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"include": "#object"
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"include": "#type-alias"
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
"include": "#function"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"include": "#variable-declaration"
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"include": "#type-constraint"
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
"include": "#type-annotation"
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"include": "#function-call"
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
"include": "#method-reference"
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"include": "#key"
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
"include": "#string"
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
"include": "#string-empty"
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"include": "#string-multiline"
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
"include": "#character"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"include": "#lambda-arrow"
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
"include": "#operators"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"include": "#self-reference"
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"include": "#decimal-literal"
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"include": "#hex-literal"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"include": "#binary-literal"
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
"include": "#boolean-literal"
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
"include": "#null-literal"
|
|
171
|
+
}
|
|
172
|
+
]
|
|
173
|
+
},
|
|
174
|
+
"comment-block": {
|
|
175
|
+
"begin": "/\\*(?!\\*)",
|
|
176
|
+
"end": "\\*/",
|
|
177
|
+
"name": "comment.block.kotlin"
|
|
178
|
+
},
|
|
179
|
+
"comment-javadoc": {
|
|
180
|
+
"patterns": [
|
|
181
|
+
{
|
|
182
|
+
"begin": "/\\*\\*",
|
|
183
|
+
"end": "\\*/",
|
|
184
|
+
"name": "comment.block.javadoc.kotlin",
|
|
185
|
+
"patterns": [
|
|
186
|
+
{
|
|
187
|
+
"match": "@(return|constructor|receiver|sample|see|author|since|suppress)\\b",
|
|
188
|
+
"name": "keyword.other.documentation.javadoc.kotlin"
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"captures": {
|
|
192
|
+
"1": {
|
|
193
|
+
"name": "keyword.other.documentation.javadoc.kotlin"
|
|
194
|
+
},
|
|
195
|
+
"2": {
|
|
196
|
+
"name": "variable.parameter.kotlin"
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
"match": "(@p(?:aram|roperty))\\s+(\\S+)"
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
"captures": {
|
|
203
|
+
"1": {
|
|
204
|
+
"name": "keyword.other.documentation.javadoc.kotlin"
|
|
205
|
+
},
|
|
206
|
+
"2": {
|
|
207
|
+
"name": "variable.parameter.kotlin"
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
"match": "(@param)\\[(\\S+)]"
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
"captures": {
|
|
214
|
+
"1": {
|
|
215
|
+
"name": "keyword.other.documentation.javadoc.kotlin"
|
|
216
|
+
},
|
|
217
|
+
"2": {
|
|
218
|
+
"name": "entity.name.type.class.kotlin"
|
|
219
|
+
}
|
|
220
|
+
},
|
|
221
|
+
"match": "(@(?:exception|throws))\\s+(\\S+)"
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
"captures": {
|
|
225
|
+
"1": {
|
|
226
|
+
"name": "keyword.other.documentation.javadoc.kotlin"
|
|
227
|
+
},
|
|
228
|
+
"2": {
|
|
229
|
+
"name": "entity.name.type.class.kotlin"
|
|
230
|
+
},
|
|
231
|
+
"3": {
|
|
232
|
+
"name": "variable.parameter.kotlin"
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
"match": "\\{(@link)\\s+(\\S+)?#([$\\w]+\\s*\\([^()]*\\)).*}"
|
|
236
|
+
}
|
|
237
|
+
]
|
|
238
|
+
}
|
|
239
|
+
]
|
|
240
|
+
},
|
|
241
|
+
"comment-line": {
|
|
242
|
+
"begin": "//",
|
|
243
|
+
"end": "$",
|
|
244
|
+
"name": "comment.line.double-slash.kotlin"
|
|
245
|
+
},
|
|
246
|
+
"comments": {
|
|
247
|
+
"patterns": [
|
|
248
|
+
{
|
|
249
|
+
"include": "#comment-line"
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
"include": "#comment-block"
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
"include": "#comment-javadoc"
|
|
256
|
+
}
|
|
257
|
+
]
|
|
258
|
+
},
|
|
259
|
+
"control-keywords": {
|
|
260
|
+
"match": "\\b(if|else|while|do|when|try|throw|break|continue|return|for)\\b",
|
|
261
|
+
"name": "keyword.control.kotlin"
|
|
262
|
+
},
|
|
263
|
+
"decimal-literal": {
|
|
264
|
+
"match": "\\b\\d[_\\d]*(\\.[_\\d]+)?(([Ee])\\d+)?([Uu])?([FLf])?\\b",
|
|
265
|
+
"name": "constant.numeric.decimal.kotlin"
|
|
266
|
+
},
|
|
267
|
+
"function": {
|
|
268
|
+
"captures": {
|
|
269
|
+
"1": {
|
|
270
|
+
"name": "keyword.hard.fun.kotlin"
|
|
271
|
+
},
|
|
272
|
+
"2": {
|
|
273
|
+
"patterns": [
|
|
274
|
+
{
|
|
275
|
+
"include": "#type-parameter"
|
|
276
|
+
}
|
|
277
|
+
]
|
|
278
|
+
},
|
|
279
|
+
"4": {
|
|
280
|
+
"name": "entity.name.type.class.extension.kotlin"
|
|
281
|
+
},
|
|
282
|
+
"5": {
|
|
283
|
+
"name": "entity.name.function.declaration.kotlin"
|
|
284
|
+
}
|
|
285
|
+
},
|
|
286
|
+
"match": "\\b(fun)\\b\\s*(?<GROUP><([^<>]|\\g<GROUP>)+>)?\\s*(?:(?:(\\w+)\\.)?(\\b\\w+\\b|`[^`]+`))?"
|
|
287
|
+
},
|
|
288
|
+
"function-call": {
|
|
289
|
+
"captures": {
|
|
290
|
+
"1": {
|
|
291
|
+
"name": "entity.name.function.call.kotlin"
|
|
292
|
+
},
|
|
293
|
+
"2": {
|
|
294
|
+
"patterns": [
|
|
295
|
+
{
|
|
296
|
+
"include": "#type-parameter"
|
|
297
|
+
}
|
|
298
|
+
]
|
|
299
|
+
}
|
|
300
|
+
},
|
|
301
|
+
"match": "\\??\\.?(\\b\\w+\\b|`[^`]+`)\\s*(?<GROUP><([^<>]|\\g<GROUP>)+>)?\\s*(?=[({])"
|
|
302
|
+
},
|
|
303
|
+
"hard-keywords": {
|
|
304
|
+
"match": "\\b(as|typeof|is|in)\\b",
|
|
305
|
+
"name": "keyword.hard.kotlin"
|
|
306
|
+
},
|
|
307
|
+
"hex-literal": {
|
|
308
|
+
"match": "0([Xx])\\h[_\\h]*([Uu])?",
|
|
309
|
+
"name": "constant.numeric.hex.kotlin"
|
|
310
|
+
},
|
|
311
|
+
"import": {
|
|
312
|
+
"begin": "\\b(import)\\b\\s*",
|
|
313
|
+
"beginCaptures": {
|
|
314
|
+
"1": {
|
|
315
|
+
"name": "keyword.soft.kotlin"
|
|
316
|
+
}
|
|
317
|
+
},
|
|
318
|
+
"contentName": "entity.name.package.kotlin",
|
|
319
|
+
"end": ";|$",
|
|
320
|
+
"name": "meta.import.kotlin",
|
|
321
|
+
"patterns": [
|
|
322
|
+
{
|
|
323
|
+
"include": "#comments"
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
"include": "#hard-keywords"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"match": "\\*",
|
|
330
|
+
"name": "variable.language.wildcard.kotlin"
|
|
331
|
+
}
|
|
332
|
+
]
|
|
333
|
+
},
|
|
334
|
+
"key": {
|
|
335
|
+
"captures": {
|
|
336
|
+
"1": {
|
|
337
|
+
"name": "variable.parameter.kotlin"
|
|
338
|
+
},
|
|
339
|
+
"2": {
|
|
340
|
+
"name": "keyword.operator.assignment.kotlin"
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
"match": "\\b(\\w=)\\s*(=)"
|
|
344
|
+
},
|
|
345
|
+
"keywords": {
|
|
346
|
+
"patterns": [
|
|
347
|
+
{
|
|
348
|
+
"include": "#prefix-modifiers"
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
"include": "#postfix-modifiers"
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"include": "#soft-keywords"
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
"include": "#hard-keywords"
|
|
358
|
+
},
|
|
359
|
+
{
|
|
360
|
+
"include": "#control-keywords"
|
|
361
|
+
}
|
|
362
|
+
]
|
|
363
|
+
},
|
|
364
|
+
"lambda-arrow": {
|
|
365
|
+
"match": "->",
|
|
366
|
+
"name": "storage.type.function.arrow.kotlin"
|
|
367
|
+
},
|
|
368
|
+
"method-reference": {
|
|
369
|
+
"captures": {
|
|
370
|
+
"1": {
|
|
371
|
+
"name": "entity.name.function.reference.kotlin"
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
"match": "\\??::(\\b\\w+\\b|`[^`]+`)"
|
|
375
|
+
},
|
|
376
|
+
"null-literal": {
|
|
377
|
+
"match": "\\bnull\\b",
|
|
378
|
+
"name": "constant.language.null.kotlin"
|
|
379
|
+
},
|
|
380
|
+
"object": {
|
|
381
|
+
"captures": {
|
|
382
|
+
"1": {
|
|
383
|
+
"name": "keyword.hard.object.kotlin"
|
|
384
|
+
},
|
|
385
|
+
"2": {
|
|
386
|
+
"name": "entity.name.type.object.kotlin"
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
"match": "\\b(object)(?:\\s+(\\b\\w+\\b|`[^`]+`))?"
|
|
390
|
+
},
|
|
391
|
+
"operators": {
|
|
392
|
+
"patterns": [
|
|
393
|
+
{
|
|
394
|
+
"match": "(===?|!==?|<=|>=|[<>])",
|
|
395
|
+
"name": "keyword.operator.comparison.kotlin"
|
|
396
|
+
},
|
|
397
|
+
{
|
|
398
|
+
"match": "([-%*+/]=)",
|
|
399
|
+
"name": "keyword.operator.assignment.arithmetic.kotlin"
|
|
400
|
+
},
|
|
401
|
+
{
|
|
402
|
+
"match": "(=)",
|
|
403
|
+
"name": "keyword.operator.assignment.kotlin"
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
"match": "([-%*+/])",
|
|
407
|
+
"name": "keyword.operator.arithmetic.kotlin"
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
"match": "(!|&&|\\|\\|)",
|
|
411
|
+
"name": "keyword.operator.logical.kotlin"
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
"match": "(--|\\+\\+)",
|
|
415
|
+
"name": "keyword.operator.increment-decrement.kotlin"
|
|
416
|
+
},
|
|
417
|
+
{
|
|
418
|
+
"match": "(\\.\\.)",
|
|
419
|
+
"name": "keyword.operator.range.kotlin"
|
|
420
|
+
}
|
|
421
|
+
]
|
|
422
|
+
},
|
|
423
|
+
"package": {
|
|
424
|
+
"begin": "\\b(package)\\b\\s*",
|
|
425
|
+
"beginCaptures": {
|
|
426
|
+
"1": {
|
|
427
|
+
"name": "keyword.hard.package.kotlin"
|
|
428
|
+
}
|
|
429
|
+
},
|
|
430
|
+
"contentName": "entity.name.package.kotlin",
|
|
431
|
+
"end": ";|$",
|
|
432
|
+
"name": "meta.package.kotlin",
|
|
433
|
+
"patterns": [
|
|
434
|
+
{
|
|
435
|
+
"include": "#comments"
|
|
436
|
+
}
|
|
437
|
+
]
|
|
438
|
+
},
|
|
439
|
+
"postfix-modifiers": {
|
|
440
|
+
"match": "\\b(where|by|get|set)\\b",
|
|
441
|
+
"name": "storage.modifier.other.kotlin"
|
|
442
|
+
},
|
|
443
|
+
"prefix-modifiers": {
|
|
444
|
+
"match": "\\b(abstract|final|enum|open|annotation|sealed|data|override|final|lateinit|private|protected|public|internal|inner|companion|noinline|crossinline|vararg|reified|tailrec|operator|infix|inline|external|const|suspend|value)\\b",
|
|
445
|
+
"name": "storage.modifier.other.kotlin"
|
|
446
|
+
},
|
|
447
|
+
"self-reference": {
|
|
448
|
+
"match": "\\b(this|super)(@\\w+)?\\b",
|
|
449
|
+
"name": "variable.language.this.kotlin"
|
|
450
|
+
},
|
|
451
|
+
"soft-keywords": {
|
|
452
|
+
"match": "\\b(init|catch|finally|field)\\b",
|
|
453
|
+
"name": "keyword.soft.kotlin"
|
|
454
|
+
},
|
|
455
|
+
"string": {
|
|
456
|
+
"begin": "(?<!\")\"(?!\")",
|
|
457
|
+
"end": "\"",
|
|
458
|
+
"name": "string.quoted.double.kotlin",
|
|
459
|
+
"patterns": [
|
|
460
|
+
{
|
|
461
|
+
"match": "\\\\.",
|
|
462
|
+
"name": "constant.character.escape.kotlin"
|
|
463
|
+
},
|
|
464
|
+
{
|
|
465
|
+
"include": "#string-escape-simple"
|
|
466
|
+
},
|
|
467
|
+
{
|
|
468
|
+
"include": "#string-escape-bracketed"
|
|
469
|
+
}
|
|
470
|
+
]
|
|
471
|
+
},
|
|
472
|
+
"string-empty": {
|
|
473
|
+
"match": "(?<!\")\"\"(?!\")",
|
|
474
|
+
"name": "string.quoted.double.kotlin"
|
|
475
|
+
},
|
|
476
|
+
"string-escape-bracketed": {
|
|
477
|
+
"begin": "(?<!\\\\)(\\$\\{)",
|
|
478
|
+
"beginCaptures": {
|
|
479
|
+
"1": {
|
|
480
|
+
"name": "punctuation.definition.template-expression.begin"
|
|
481
|
+
}
|
|
482
|
+
},
|
|
483
|
+
"end": "(})",
|
|
484
|
+
"endCaptures": {
|
|
485
|
+
"1": {
|
|
486
|
+
"name": "punctuation.definition.template-expression.end"
|
|
487
|
+
}
|
|
488
|
+
},
|
|
489
|
+
"name": "meta.template.expression.kotlin",
|
|
490
|
+
"patterns": [
|
|
491
|
+
{
|
|
492
|
+
"include": "#code"
|
|
493
|
+
}
|
|
494
|
+
]
|
|
495
|
+
},
|
|
496
|
+
"string-escape-simple": {
|
|
497
|
+
"match": "(?<!\\\\)\\$\\w+\\b",
|
|
498
|
+
"name": "variable.string-escape.kotlin"
|
|
499
|
+
},
|
|
500
|
+
"string-multiline": {
|
|
501
|
+
"begin": "\"\"\"",
|
|
502
|
+
"end": "\"\"\"",
|
|
503
|
+
"name": "string.quoted.double.kotlin",
|
|
504
|
+
"patterns": [
|
|
505
|
+
{
|
|
506
|
+
"match": "\\\\.",
|
|
507
|
+
"name": "constant.character.escape.kotlin"
|
|
508
|
+
},
|
|
509
|
+
{
|
|
510
|
+
"include": "#string-escape-simple"
|
|
511
|
+
},
|
|
512
|
+
{
|
|
513
|
+
"include": "#string-escape-bracketed"
|
|
514
|
+
}
|
|
515
|
+
]
|
|
516
|
+
},
|
|
517
|
+
"type-alias": {
|
|
518
|
+
"captures": {
|
|
519
|
+
"1": {
|
|
520
|
+
"name": "keyword.hard.typealias.kotlin"
|
|
521
|
+
},
|
|
522
|
+
"2": {
|
|
523
|
+
"name": "entity.name.type.kotlin"
|
|
524
|
+
},
|
|
525
|
+
"3": {
|
|
526
|
+
"patterns": [
|
|
527
|
+
{
|
|
528
|
+
"include": "#type-parameter"
|
|
529
|
+
}
|
|
530
|
+
]
|
|
531
|
+
}
|
|
532
|
+
},
|
|
533
|
+
"match": "\\b(typealias)\\s+(\\b\\w+\\b|`[^`]+`)\\s*(?<GROUP><([^<>]|\\g<GROUP>)+>)?"
|
|
534
|
+
},
|
|
535
|
+
"type-annotation": {
|
|
536
|
+
"captures": {
|
|
537
|
+
"0": {
|
|
538
|
+
"patterns": [
|
|
539
|
+
{
|
|
540
|
+
"include": "#type-parameter"
|
|
541
|
+
}
|
|
542
|
+
]
|
|
543
|
+
}
|
|
544
|
+
},
|
|
545
|
+
"match": "(?<![:?]):\\s*([?\\w\\s]|->|(?<GROUP>[(<]([^\"'()<>]|\\g<GROUP>)+[)>]))+"
|
|
546
|
+
},
|
|
547
|
+
"type-parameter": {
|
|
548
|
+
"patterns": [
|
|
549
|
+
{
|
|
550
|
+
"match": "\\b\\w+\\b",
|
|
551
|
+
"name": "entity.name.type.kotlin"
|
|
552
|
+
},
|
|
553
|
+
{
|
|
554
|
+
"match": "\\b(in|out)\\b",
|
|
555
|
+
"name": "storage.modifier.kotlin"
|
|
556
|
+
}
|
|
557
|
+
]
|
|
558
|
+
},
|
|
559
|
+
"unescaped-annotation": {
|
|
560
|
+
"match": "\\b[.\\w]+\\b",
|
|
561
|
+
"name": "entity.name.type.annotation.kotlin"
|
|
562
|
+
},
|
|
563
|
+
"variable-declaration": {
|
|
564
|
+
"captures": {
|
|
565
|
+
"1": {
|
|
566
|
+
"name": "keyword.hard.kotlin"
|
|
567
|
+
},
|
|
568
|
+
"2": {
|
|
569
|
+
"patterns": [
|
|
570
|
+
{
|
|
571
|
+
"include": "#type-parameter"
|
|
572
|
+
}
|
|
573
|
+
]
|
|
574
|
+
}
|
|
575
|
+
},
|
|
576
|
+
"match": "\\b(va[lr])\\b\\s*(?<GROUP><([^<>]|\\g<GROUP>)+>)?"
|
|
577
|
+
}
|
|
578
|
+
},
|
|
579
|
+
"scopeName": "source.kotlin"
|
|
580
|
+
}
|