Repository navigation
Expand file tree
/
Copy pathpackage.json
More file actions
617 lines (617 loc) · 18.5 KB
/
Copy pathpackage.json
File metadata and controls
617 lines (617 loc) · 18.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
{
"name": "ny-language-support",
"displayName": "NIL Framework (Ny + Matrix)",
"description": "Ny and Matrix language support, NILData highlighting, and native/VM toolchain integration for the NIL Framework.",
"version": "1.0.0-rc.1",
"publisher": "exec-software",
"license": "MIT",
"author": "Execute Software",
"repository": {
"type": "git",
"url": "https://github.com/exec-software/exec-nil-framework.git",
"directory": "vscode"
},
"bugs": {
"url": "https://github.com/exec-software/exec-nil-framework/issues"
},
"engines": {
"vscode": "^1.95.0"
},
"categories": [
"Programming Languages"
],
"keywords": [
"nil",
"nil framework",
"ny",
"matrix",
"systems programming",
"language server",
"lsp",
"nildata"
],
"main": "./dist/extension.js",
"extensionKind": [
"workspace"
],
"activationEvents": [
"onLanguage:ny",
"onLanguage:matrix",
"onTaskType:ny",
"onDebug:ny",
"onCommand:ny.restartLanguageServer",
"onCommand:ny.showLanguageServerOutput",
"onCommand:ny.selectSdk",
"onCommand:ny.compileCurrentFile",
"onCommand:ny.runCurrentFile",
"onCommand:ny.compileNativeCurrentFile",
"onCommand:ny.buildSdk",
"onCommand:ny.runCtest",
"workspaceContains:**/*.ny",
"workspaceContains:**/*.matrix",
"workspaceContains:**/*.mat",
"onCommand:ny.analyzeCurrentFile",
"onCommand:ny.showAnalysisOutput",
"onCommand:ny.checkProject",
"onCommand:ny.checkNativeProject",
"onCommand:ny.buildProject",
"onCommand:ny.buildNativeProject",
"onCommand:ny.runProject",
"onCommand:ny.runNativeProject",
"workspaceContains:**/nil.project.nildata",
"workspaceContains:**/nil.project.json",
"workspaceContains:**/nil.project.yaml",
"workspaceContains:**/nil.project.yml",
"onCommand:ny.profileMemory",
"onCommand:ny.profileNativeMemory",
"onCommand:ny.discoverTests"
],
"capabilities": {
"untrustedWorkspaces": {
"supported": "limited",
"description": "Syntax highlighting, indentation, and snippets remain available. NIL Framework executables and tasks are disabled until the workspace is trusted."
},
"virtualWorkspaces": {
"supported": false,
"description": "The NIL Framework toolchain currently requires files on a local filesystem."
}
},
"scripts": {
"check": "tsc --noEmit -p tsconfig.json",
"build": "node esbuild.mjs --production",
"watch": "node esbuild.mjs --watch",
"test": "npm run check && npm run test:unit",
"test:unit": "tsc -p tsconfig.test.json && node --test out-test/test/*.test.js",
"package": "npm run test && npm run build && vsce package",
"vscode:prepublish": "npm run build",
"test:host": "npm run build && node test/run-host.cjs"
},
"dependencies": {
"vscode-languageclient": "^10.1.1"
},
"devDependencies": {
"@types/node": "^22.20.2",
"@types/vscode": "1.95.0",
"@vscode/vsce": "^4.0.0",
"esbuild": "^0.28.2",
"typescript": "^7.0.2",
"vscode-oniguruma": "^2.0.1",
"vscode-textmate": "^9.3.2"
},
"contributes": {
"breakpoints": [
{
"language": "ny"
},
{
"language": "matrix"
}
],
"debuggers": [
{
"type": "ny",
"label": "NIL Framework source debugger",
"languages": [
"ny",
"matrix"
],
"configurationAttributes": {
"launch": {
"required": [
"program"
],
"properties": {
"program": {
"type": "string",
"description": "Ny (.ny), Matrix (.matrix, .mat), or NIL compiled with --debug-info."
},
"args": {
"type": "array",
"items": {
"type": "string"
},
"default": []
},
"cwd": {
"type": "string",
"description": "Program working directory."
},
"stopOnEntry": {
"type": "boolean",
"default": true
},
"memoryMode": {
"type": "string",
"enum": [
"safe",
"unsafe"
],
"default": "safe"
}
}
}
},
"initialConfigurations": [
{
"type": "ny",
"request": "launch",
"name": "Debug Ny / Matrix file",
"program": "${file}",
"stopOnEntry": true
}
],
"configurationSnippets": [
{
"label": "NIL Framework: Debug Ny / Matrix source file",
"body": {
"type": "ny",
"request": "launch",
"name": "Debug Ny / Matrix file",
"program": "${file}",
"stopOnEntry": true
}
}
]
}
],
"languages": [
{
"id": "ny",
"aliases": [
"Ny",
"ny"
],
"extensions": [
".ny"
],
"configuration": "./language-configuration.json"
},
{
"id": "matrix",
"aliases": [
"Matrix",
"matrix"
],
"extensions": [
".matrix",
".mat"
],
"configuration": "./language-configuration.matrix.json"
},
{
"id": "nildata",
"aliases": [
"NILData",
"nildata"
],
"extensions": [
".nildata"
],
"configuration": "./language-configuration.nildata.json"
}
],
"grammars": [
{
"language": "ny",
"scopeName": "source.ny",
"path": "./syntaxes/ny.tmLanguage.json",
"embeddedLanguages": {
"meta.embedded.expression.ny": "ny"
},
"tokenTypes": {
"meta.embedded.expression.ny": "other"
}
},
{
"language": "matrix",
"scopeName": "source.matrix",
"path": "./syntaxes/matrix.tmLanguage.json",
"embeddedLanguages": {
"meta.embedded.expression.matrix": "matrix"
},
"tokenTypes": {
"meta.embedded.expression.matrix": "other"
}
},
{
"language": "nildata",
"scopeName": "source.nildata",
"path": "./syntaxes/nildata.tmLanguage.json"
}
],
"snippets": [
{
"language": "ny",
"path": "./snippets/ny.code-snippets"
},
{
"language": "matrix",
"path": "./snippets/matrix.code-snippets"
}
],
"commands": [
{
"command": "ny.restartLanguageServer",
"title": "NIL Framework: Restart Language Server"
},
{
"command": "ny.showLanguageServerOutput",
"title": "NIL Framework: Show Language Server Output"
},
{
"command": "ny.selectSdk",
"title": "NIL Framework: Select SDK Folder"
},
{
"command": "ny.compileCurrentFile",
"title": "NIL Framework: Compile Current File to NIL"
},
{
"command": "ny.runCurrentFile",
"title": "NIL Framework: Compile and Run Current File"
},
{
"command": "ny.compileNativeCurrentFile",
"title": "NIL Framework: Compile Current File Natively"
},
{
"command": "ny.buildSdk",
"title": "NIL Framework: Build and Install Workspace SDK"
},
{
"command": "ny.runCtest",
"title": "NIL Framework: Run Workspace CTest Suite"
},
{
"command": "ny.analyzeCurrentFile",
"title": "NIL Framework: Check Current Document"
},
{
"command": "ny.showAnalysisOutput",
"title": "NIL Framework: Show Analysis Output"
},
{
"command": "ny.checkProject",
"title": "NIL Framework: Check Project (VM)"
},
{
"command": "ny.checkNativeProject",
"title": "NIL Framework: Check Project (Native)"
},
{
"command": "ny.buildProject",
"title": "NIL Framework: Build Project (VM)"
},
{
"command": "ny.buildNativeProject",
"title": "NIL Framework: Build Project (Native)"
},
{
"command": "ny.runProject",
"title": "NIL Framework: Build and Run Project (VM)"
},
{
"command": "ny.runNativeProject",
"title": "NIL Framework: Build and Run Project (Native)"
},
{
"command": "ny.profileMemory",
"title": "NIL Framework: Profile Current File Memory (VM)"
},
{
"command": "ny.profileNativeMemory",
"title": "NIL Framework: Profile Current File Memory (Native)"
},
{
"command": "ny.discoverTests",
"title": "NIL Framework: Discover Tests in Current File or Project"
}
],
"configuration": {
"title": "NIL Framework (Ny + Matrix)",
"properties": {
"ny.languageServer.enabled": {
"type": "boolean",
"default": true,
"scope": "window",
"description": "Start nillsp for Ny and Matrix source files. The server provides completion, navigation, hover, and experimental diagnostics."
},
"ny.languageServer.diagnostics.enabled": {
"type": "boolean",
"default": false,
"scope": "window",
"description": "Show nillsp diagnostics for Ny and Matrix. Disabled by default because the lightweight server parser does not yet understand all canonical source syntax."
},
"ny.sdkPath": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Path to a canonical NIL Framework SDK root or framework repository root. SDK commands live directly at the SDK root. Supports ${workspaceFolder}, ${env:NAME}, and ~."
},
"ny.server.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for nillsp. Overrides SDK and PATH discovery."
},
"ny.compiler.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for nilcompiler. Overrides SDK and PATH discovery."
},
"ny.interpreter.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for nilinterpreter. Overrides SDK and PATH discovery."
},
"ny.debugger.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for nildebugger. Overrides SDK and PATH discovery."
},
"ny.compiler.noStdlib": {
"type": "boolean",
"default": false,
"scope": "resource",
"description": "Pass --no-stdlib to compiler tasks and editor analysis."
},
"ny.compiler.extraArgs": {
"type": "array",
"items": {
"type": "string"
},
"default": [],
"scope": "resource",
"description": "Additional arguments placed before extension-managed nilcompiler arguments."
},
"ny.native.extraArgs": {
"type": "array",
"items": {
"type": "string"
},
"default": [],
"scope": "resource",
"description": "Additional arguments used only for LLVM native compiler tasks."
},
"ny.outputDirectory": {
"type": "string",
"default": "",
"scope": "resource",
"description": "Output directory for generated artifacts. Empty writes beside the current source file."
},
"ny.buildDirectory": {
"type": "string",
"default": "build/cmake",
"scope": "resource",
"description": "Workspace-relative CMake build directory used by the CTest task."
},
"ny.trace.server": {
"type": "string",
"enum": [
"off",
"messages",
"verbose"
],
"default": "off",
"scope": "window",
"description": "Trace messages exchanged with nillsp in the language server output channel."
},
"ny.analysis.enabled": {
"type": "boolean",
"default": true,
"scope": "resource",
"description": "Check Ny and Matrix sources and unsaved imports, and provide compiler-resolved definitions, identifier/member completion, signature help, certified local references and rename. Requires a trusted workspace and a current SDK supporting --workspace-stdin, --semantic-index, --completion-at, --signature-at and nil.analysis.v1 results."
},
"ny.analysis.includePaths": {
"type": "array",
"items": {
"type": "string"
},
"default": [],
"scope": "resource",
"description": "Additional source import roots for compiler analysis. Relative paths resolve against the workspace folder. Supports ${workspaceFolder}, ${env:NAME}, and ~."
},
"ny.projectTool.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for nilbuild. Overrides SDK and PATH discovery."
},
"ny.aperture.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for Aperture. Overrides SDK and PATH discovery."
},
"ny.testTool.path": {
"type": "string",
"default": "",
"scope": "machine-overridable",
"description": "Absolute path or command name for niltest. Overrides SDK and PATH discovery."
},
"ny.testing.timeoutSeconds": {
"type": "number",
"default": 30,
"minimum": 1,
"maximum": 300,
"scope": "resource",
"description": "Maximum execution time per test in the NIL Test Explorer run profiles."
}
}
},
"taskDefinitions": [
{
"type": "ny",
"required": [
"task"
],
"properties": {
"task": {
"type": "string",
"enum": [
"compile",
"run",
"native",
"build-sdk",
"ctest",
"project-check",
"project-build",
"project-run",
"profile-memory",
"profile-memory-native"
],
"description": "NIL Framework task to execute."
},
"source": {
"type": "string",
"description": "Ny (.ny) or Matrix (.matrix, .mat) source path. Defaults to the active saved source file."
},
"output": {
"type": "string",
"description": "NIL or native output path."
},
"sdkPath": {
"type": "string",
"description": "SDK/source search root passed to nilcompiler."
},
"noStdlib": {
"type": "boolean",
"description": "Compile without standard-library lookup."
},
"args": {
"type": "array",
"items": {
"type": "string"
},
"description": "Additional compiler, interpreter, or CTest options. Interpreter options are placed before the NIL path."
},
"programArgs": {
"type": "array",
"items": {
"type": "string"
},
"description": "Arguments passed to the program by a run task after an explicit -- separator."
},
"buildDirectory": {
"type": "string",
"description": "CMake build directory for ctest."
},
"project": {
"type": "string",
"description": "Path to nil.project.nildata or a legacy JSON/YAML manifest. Defaults to the nearest project within the active workspace."
},
"target": {
"type": "string",
"enum": [
"vm",
"native"
],
"default": "vm",
"description": "Backend used by project tasks."
}
}
}
],
"problemMatchers": [
{
"name": "nilcompiler",
"label": "NIL compiler Ny parse errors",
"owner": "ny",
"source": "nilcompiler",
"fileLocation": "absolute",
"pattern": {
"regexp": "^\\s*(.+\\.(?:[nN][yY]|[mM][aA][tT](?:[rR][iI][xX])?)):(\\d+):\\s+(.*)$",
"file": 1,
"line": 2,
"message": 3
}
},
{
"name": "matrixcompiler",
"label": "Matrix compiler errors",
"owner": "matrix",
"source": "nilcompiler",
"fileLocation": "absolute",
"pattern": [
{
"regexp": "^(error|warning|note)(?:\\[([^\\]]*)\\])?:\\s+(.*)$",
"severity": 1,
"code": 2,
"message": 3
},
{
"regexp": "^\\s*-->\\s+(.+\\.(?:[nN][yY]|[mM][aA][tT](?:[rR][iI][xX])?)):(\\d+)(?::(\\d+))?\\s*$",
"file": 1,
"line": 2,
"column": 3
}
]
},
{
"name": "nycompiler",
"label": "NIL compiler Ny parse errors (legacy matcher name)",
"owner": "ny",
"source": "nilcompiler",
"fileLocation": "absolute",
"pattern": {
"regexp": "^\\s*(.+\\.(?:[nN][yY]|[mM][aA][tT](?:[rR][iI][xX])?)):(\\d+):\\s+(.*)$",
"file": 1,
"line": 2,
"message": 3
}
},
{
"name": "nilproject",
"label": "NIL project analysis",
"owner": "nil-project",
"source": "nilbuild",
"fileLocation": "absolute",
"pattern": {
"regexp": "^(.+):(\\d+):(\\d+): (error|warning|note|help) ([^:]+): (.*)$",
"file": 1,
"line": 2,
"column": 3,
"severity": 4,
"code": 5,
"message": 6
}
}
],
"jsonValidation": [
{
"fileMatch": [
"nil.project.json"
],
"url": "./schemas/nil.project.schema.json"
}
]
},
"overrides": {
"@azure/identity": {
"@azure/msal-node": "7.1.1"
}
}
}