-
Notifications
You must be signed in to change notification settings - Fork 27
/
package.json
687 lines (687 loc) · 22.4 KB
/
package.json
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
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
{
"name": "pico-w-go",
"displayName": "MicroPico",
"description": "Auto-completion, remote workspace and a REPL console integration for the Raspberry Pi Pico boards running MicroPython firmware.",
"version": "4.1.0",
"publisher": "paulober",
"license": "MPL-2.0",
"homepage": "https://github.com/paulober/MicroPico/blob/main/README.md",
"bugs": {
"url": "https://github.com/paulober/MicroPico/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/paulober/MicroPico.git"
},
"icon": "images/logo-256.png",
"galleryBanner": {
"color": "#5666c6",
"theme": "dark"
},
"markdown": "github",
"engines": {
"vscode": "^1.92.1",
"node": ">=20.14.0"
},
"keywords": [
"raspberry",
"pi",
"pico",
"pico w",
"raspberry pi pico",
"raspberry pi pico w",
"micropython",
"pico-w-go"
],
"categories": [
"Other"
],
"capabilities": {
"virtualWorkspaces": {
"supported": "limited",
"description": "MicroPico does not support as first workspace a virtual one but contributes a virtual workspace for the Pico (W)."
},
"untrustedWorkspaces": {
"supported": false,
"description": "Why would you want to use MicroPico in an untrusted workspace?"
}
},
"extensionDependencies": [
"ms-python.python"
],
"activationEvents": [
"workspaceContains:.picowgo",
"workspaceContains:.micropico",
"onFileSystem:pico"
],
"main": "./dist/extension.cjs",
"os": [
"win32",
"darwin",
"linux"
],
"cpu": [
"x64",
"arm64",
"arm"
],
"minimumNodeVersion": 20,
"contributes": {
"commands": [
{
"command": "micropico.connect",
"title": "Connect",
"category": "MicroPico"
},
{
"command": "micropico.disconnect",
"title": "Disconnect",
"category": "MicroPico"
},
{
"command": "micropico.initialise",
"title": "Setup MicroPico project",
"enablement": "(resourceScheme != pico && isFileSystemResource) || inQuickOpen",
"category": "MicroPico"
},
{
"command": "micropico.upload",
"title": "Upload project to Pico",
"enablement": "micropico.isConnected && (resourceScheme != pico && isFileSystemResource) || inQuickOpen",
"category": "MicroPico"
},
{
"command": "micropico.uploadFile",
"title": "Upload file to Pico",
"enablement": "micropico.isConnected && resourceScheme != pico && isFileSystemResource",
"category": "MicroPico"
},
{
"command": "micropico.downloadFile",
"title": "Download file from Pico",
"enablement": "micropico.isConnected && resourceScheme == pico && isFileSystemResource"
},
{
"command": "micropico.download",
"title": "Download project from Pico",
"enablement": "(resourceScheme == pico && isFileSystemResource) || inQuickOpen",
"category": "MicroPico"
},
{
"command": "micropico.run",
"title": "Run current file on Pico",
"enablement": "micropico.isConnected && resourceScheme != pico && isFileSystemResource && resourceExtname == .py",
"category": "MicroPico"
},
{
"command": "micropico.remote.run",
"title": "Run current file on Pico",
"enablement": "resourceScheme == pico && isFileSystemResource && resourceExtname == .py",
"category": "MicroPico"
},
{
"command": "micropico.universalStop",
"title": "Stop execution",
"category": "MicroPico"
},
{
"command": "micropico.runselection",
"title": "Run current selection on Pico",
"enablement": "micropico.isConnected && !inQuickOpen && !listFocus && editorLangId == python",
"category": "MicroPico"
},
{
"command": "micropico.deleteAllFiles",
"title": "Delete all files from board",
"category": "MicroPico"
},
{
"command": "micropico.globalSettings",
"title": "Global settings",
"category": "MicroPico"
},
{
"command": "micropico.workspaceSettings",
"title": "Workspace settings",
"category": "MicroPico"
},
{
"command": "micropico.reset.soft",
"title": "Reset > Soft",
"category": "MicroPico"
},
{
"command": "micropico.reset.hard",
"title": "Reset > Hard",
"category": "MicroPico"
},
{
"command": "micropico.reset.hard.listen",
"title": "Reset > Hard (interactive)",
"category": "MicroPico"
},
{
"command": "micropico.help",
"title": "Help > Getting started",
"category": "MicroPico"
},
{
"command": "micropico.extra.pins",
"title": "Help > Show Pico Pin Map",
"category": "MicroPico"
},
{
"command": "micropico.extra.getSerial",
"title": "Help > List serial ports",
"category": "MicroPico"
},
{
"command": "micropico.extra.firmwareUpdates",
"title": "Help > Check for firmware updates",
"category": "MicroPico"
},
{
"command": "micropico.extra.switchStubs",
"title": "Extra > Switch stubs",
"category": "MicroPico"
},
{
"command": "micropico.listCommands",
"title": "List all Commands",
"category": "MicroPico"
},
{
"command": "micropico.toggleFileSystem",
"title": "Toggle Virtual File System (reloads UI and closes existing vREPLs)",
"category": "MicroPico"
},
{
"command": "micropico.switchPico",
"title": "Switch Pico",
"category": "MicroPico"
},
{
"command": "micropico.reset.soft.listen",
"title": "Reset > Soft (interactive)",
"category": "MicroPico"
},
{
"command": "micropico.rtc.sync",
"title": "Sync RTC",
"category": "MicroPico"
},
{
"command": "micropico.device-wifi.itemClicked",
"title": "Wifi > Connect",
"category": "MicroPico"
},
{
"command": "micropico.device-wifi.refresh",
"title": "Scan",
"icon": {
"dark": "images/refresh-dark.svg",
"light": "images/refresh-light.svg"
},
"enablement": "view == micropico-device-wifi"
},
{
"command": "micropico.garbageCollect",
"title": "Trigger garbage collection",
"category": "MicroPico"
},
{
"command": "micropico.flashPico",
"title": "Flash Pico in BOOTSEL mode",
"category": "MicroPico"
},
{
"command": "micropico.redirectOutput",
"title": "MicroPython output redirection settings (experimental)",
"category": "MicroPico",
"enablement": "micropico.isConnected"
}
],
"menus": {
"explorer/context": [
{
"command": "micropico.upload",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico"
},
{
"command": "micropico.uploadFile",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico"
},
{
"command": "micropico.downloadFile",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico"
},
{
"command": "micropico.download",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico"
},
{
"command": "micropico.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico && isFileSystemResource && resourceExtname == .py"
},
{
"command": "micropico.remote.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico && isFileSystemResource && resourceExtname == .py"
},
{
"command": "micropico.initialise",
"group": "micropico",
"when": "resourceScheme != pico"
}
],
"editor/context": [
{
"command": "micropico.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico && isFileSystemResource && resourceExtname == .py && editorLangId == python"
},
{
"command": "micropico.remote.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico && isFileSystemResource && resourceExtname == .py && editorLangId == python"
},
{
"command": "micropico.runselection",
"group": "micropico",
"when": "micropico.isActivated"
},
{
"command": "micropico.uploadFile",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico && isFileSystemResource"
}
],
"editor/title": [
{
"command": "micropico.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico && isFileSystemResource && resourceExtname == .py && editorLangId == python"
},
{
"command": "micropico.remote.run",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico && isFileSystemResource && resourceExtname == .py && editorLangId == python"
},
{
"command": "micropico.upload",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme != pico"
},
{
"command": "micropico.download",
"group": "micropico",
"when": "micropico.isActivated && resourceScheme == pico"
}
],
"view/title": [
{
"command": "micropico.device-wifi.refresh",
"when": "view == micropico-device-wifi",
"group": "navigation@0"
}
],
"terminal/context": [
{
"command": "micropico.redirectOutput",
"group": "MicroPico",
"when": "micropico.isConnected"
}
]
},
"configuration": {
"title": "MicroPico",
"properties": {
"micropico.autoConnect": {
"type": "boolean",
"scope": "machine-overridable",
"default": true,
"title": "Autoconnect on USB",
"description": "Ignores any 'device address' setting and automatically connects to the top item in the serialport list.",
"order": 2
},
"micropico.manualComDevice": {
"type": "string",
"scope": "machine-overridable",
"default": "",
"title": "Manual COM device",
"description": "If autoConnect is set to false MicroPico will automatically connect to the serial port specified here.",
"order": 3
},
"micropico.syncFolder": {
"type": "string",
"scope": "machine-overridable",
"default": null,
"title": "Sync Folder",
"description": "This folder will be uploaded to the pyboard when using the sync button. Leave empty to sync the complete project. (only allows folders within the project). Use a path relative to the project you opened in vscode, without leading or trailing slash",
"order": 4
},
"micropico.additionalSyncFolders": {
"type": "array",
"scope": "machine-overridable",
"items": {
"type": "string",
"uniqueItems": true
},
"default": [],
"title": "Additional Sync Folders",
"description": "Specifies additional folders that can be selected as upload sources when uploading a project. If left empty, the sync will be performed based on the folder specified in the 'syncFolder' setting. Only folders within the project are allowed. Specify the path relative to the project you have opened in Visual Studio Code, without a leading or trailing slash.",
"order": 5
},
"micropico.syncAllFileTypes": {
"type": "boolean",
"scope": "machine-overridable",
"default": false,
"title": "Upload all file types",
"description": "If enabled, all files will be uploaded no matter the file type. The list of file types below will be ignored",
"order": 6
},
"micropico.syncFileTypes": {
"type": "array",
"scope": "machine-overridable",
"items": {
"type": "string",
"uniqueItems": true
},
"default": [
"py",
"txt",
"log",
"json",
"xml",
"html",
"js",
"css",
"mpy"
],
"title": "Upload file types",
"description": "All types of files that will be uploaded to the board, seperated by comma. All other filetypes will be ignored during an upload (or download) action",
"order": 7
},
"micropico.pyIgnore": {
"title": "Pyignore list",
"scope": "machine-overridable",
"markdownDescription": "Comma separated list of files and folders to ignore when uploading relative to syncFolder (no wildcard or regular expressions supported except `**/<file/folder>` to exclude an item by its name in every sub folder). Use `<additionalSyncFolder>:file/to/exclude.py` to create sync folder exclusive exclusion rules (all other rules will always be applied relative to the selected sync folder). Replace `additionalSyncFolder` with a value from your `micropico.additionalSyncFolders` setting or the value from `micropico.syncFolder`.",
"type": "array",
"items": {
"type": "string"
},
"default": [
"**/.picowgo",
"**/.micropico",
"**/.vscode",
"**/.gitignore",
"**/.git",
"**/.DS_Store",
"**/project.pico-go",
"**/env",
"**/venv",
"**/.venv",
"**/.idea"
],
"order": 8
},
"micropico.openOnStart": {
"type": "boolean",
"default": false,
"scope": "machine-overridable",
"title": "Open on start",
"description": "Automatically open the MicroPico vREPL after starting VS Code. Could cause random terminal freezes on Linux.",
"order": 9
},
"micropico.statusbarButtons": {
"type": "array",
"scope": "machine-overridable",
"title": "Statusbar buttons",
"description": "Select which buttons to show in the statusbar",
"items": {
"type": "string",
"uniqueItems": true,
"enum": [
"status",
"stop",
"run",
"runselection",
"upload",
"download",
"disconnect",
"softreset",
"settings",
"listserial",
"listcommands",
"togglepicowfs",
"uploadproject",
"downloadproject"
]
},
"default": [
"status",
"run",
"softreset",
"togglepicowfs"
],
"order": 10
},
"micropico.gcBeforeUpload": {
"type": "boolean",
"default": true,
"scope": "machine-overridable",
"title": "Garbage collection before upload",
"description": "Run garbage collection before uploading files to the board. This will free up some memory usefull when uploading large files but adds about a second or two to the upload process.",
"order": 11
},
"micropico.softResetAfterUpload": {
"type": "boolean",
"scope": "machine-overridable",
"default": false,
"title": "Soft-reset after upload",
"description": "Soft-resets your board after any upload action which also reruns main.py and boot.py. Usefull when working with main.py and boot.py.",
"order": 12
},
"micropico.executeOnConnect": {
"type": "string",
"scope": "machine-overridable",
"default": "",
"title": "Script to execute on connect",
"description": "Path to a MicroPython script on the Pico to execute on connect. Leave empty to disable.",
"order": 13
},
"micropico.importOnConnect": {
"type": "string",
"scope": "machine-overridable",
"default": "",
"title": "MicroPython module to import on connect",
"description": "A MicroPython module to import in vREPL on connect. Leave empty to disable.",
"order": 14
},
"micropico.noSoftResetOnRun": {
"type": "boolean",
"scope": "machine-overridable",
"default": false,
"title": "Disable the soft-resets before and after executing a file.",
"description": "Soft-resets are used to clean REPL state so changes in classes and other structs are reflected correctly.",
"order": 15
}
}
},
"terminal": {
"profiles": [
{
"title": "MicroPico vREPL",
"id": "micropico.vrepl"
}
]
},
"viewsContainers": {
"activitybar": [
{
"id": "micropico-device-controller",
"title": "MicroPico Device Controller (experimental)",
"icon": "images/logo-black.png"
}
]
},
"views": {
"micropico-device-controller": [
{
"id": "micropico-device-wifi",
"name": "Wifi (Pico-W only)",
"type": "tree"
},
{
"id": "micropico-device-packages",
"name": "Packages (Pico-W only)",
"type": "webview"
}
]
}
},
"statusBar": [
{
"key": "status",
"name": "",
"command": "micropico.toggleConnect",
"tooltip": "Toggle board connection"
},
{
"key": "stop",
"name": "$(primitive-square) Stop",
"command": "micropico.universalStop",
"tooltip": "Stop"
},
{
"key": "run",
"name": "$(play) Run",
"command": "micropico.run",
"tooltip": "Run current file"
},
{
"key": "runselection",
"name": "$(play) Run Line",
"command": "micropico.runselection",
"tooltip": "Run selected lines"
},
{
"key": "upload",
"name": "$(triangle-up) Upload",
"command": "micropico.uploadFile",
"tooltip": "Upload current file to your board"
},
{
"key": "download",
"name": "$(triangle-down) Download",
"command": "micropico.downloadFile",
"tooltip": "Download current file to your board"
},
{
"key": "uploadproject",
"name": "$(triangle-up) Upload Project",
"command": "micropico.upload",
"tooltip": "Upload current project to your board"
},
{
"key": "downloadproject",
"name": "$(triangle-down) Download",
"command": "micropico.download",
"tooltip": "Download project from your board. This will overwrite all files in the sync folder."
},
{
"key": "disconnect",
"name": "$(chrome-close) Disconnect",
"command": "micropico.disconnect",
"tooltip": "Disconnect"
},
{
"key": "softreset",
"name": "$(refresh) Reset",
"command": "micropico.reset.soft",
"tooltip": "Clears the state of the MicroPython virtual machine"
},
{
"key": "settings",
"name": "$(gear) Settings",
"command": "micropico.globalSettings",
"tooltip": "Global MicroPico settings"
},
{
"key": "listserial",
"name": "$(list-unordered) List serial ports",
"command": "micropico.extra.getSerial",
"tooltip": "List available serial ports"
},
{
"key": "listcommands",
"name": "$(list-unordered) All commands",
"command": "micropico.listCommands",
"tooltip": "List all available MicroPico commands"
},
{
"key": "togglepicowfs",
"name": "$(list-tree) Toggle Mpy FS",
"command": "micropico.toggleFileSystem",
"tooltip": "Toggle virtual MicroPico workspace"
}
],
"scripts": {
"vscode:uninstall": "node ./dist/vscodeUninstall.mjs",
"vscode:prepublish": "npm run package",
"postinstall": "patch-package && python3 -m pip install -U micropython-rp2-rpi_pico_w-stubs==1.23.* --target ./mpy_stubs --no-user",
"cp-prebuilds": "cp -r node_modules/@serialport/bindings-cpp/prebuilds ./prebuilds",
"compile-uninstaller": "rollup -c uninstall.rollup.config.mjs --environment BUILD:production",
"compile": "rollup -c && npm run compile-uninstaller",
"watch": "npm run cp-prebuilds && rollup -cw",
"package-local": "rimraf dist && rollup -c --environment BUILD:production --sourcemap hidden && npm run compile-uninstaller",
"package": "rollup -c --environment BUILD:production && npm run compile-uninstaller",
"compile-tests": "tsc -p . --outDir out",
"watch-tests": "tsc -p . -w --outDir out",
"pretest": "npm run compile-tests && npm run compile && npm run lint",
"lint": "eslint src",
"test": "node ./out/test/runTest.js"
},
"devDependencies": {
"@eslint/js": "^9.15.0",
"@rollup/plugin-commonjs": "^28.0.1",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-terser": "^0.4.4",
"@rollup/plugin-typescript": "^12.1.1",
"@serialport/bindings-cpp": "^12.0.1",
"@types/eslint": "^9.6.1",
"@types/fs-extra": "^11.0.4",
"@types/lodash": "^4.17.13",
"@types/node": "^20.14",
"@types/uuid": "^10.0.0",
"@types/vscode": "^1.92.0",
"@types/which": "^3.0.4",
"@vscode/test-electron": "^2.4.1",
"eslint": "^9.15.0",
"eslint-config-prettier": "^9.1.0",
"patch-package": "^8.0.0",
"rollup": "^4.27.2",
"rollup-plugin-copy": "^3.5.0",
"tslib": "^2.8.1",
"typescript": "^5.6.3",
"typescript-eslint": "^8.14.0"
},
"dependencies": {
"@paulober/pico-mpy-com": "^1.0.21",
"@vscode/python-extension": "^1.0.5",
"axios": "^1.7.7",
"fs-extra": "^11.2.0",
"lodash": "^4.17.21",
"rimraf": "^6.0.1",
"undici": "^6.21.0",
"uuid": "^11.0.3",
"which": "^5.0.0"
},
"packageManager": "npm@10.8.3+sha512.d08425c8062f56d43bb8e84315864218af2492eb769e1f1ca40740f44e85bd148969382d651660363942e5909cb7ffcbef7ca0ae963ddc2c57a51243b4da8f56"
}