Files
8bitworkshop/extension/package.json
T

685 lines
22 KiB
JSON

{
"name": "8bitworkshop",
"displayName": "8bitworkshop",
"description": "Build, run, and debug 8-bit programs — NES, Atari, C-64, and more — with 8bitworkshop's 6502/Z80/6809 assemblers, compilers, and emulators",
"keywords": [
"retro",
"vintage",
"8-bit",
"8bit",
"6502",
"assembly",
"assembler",
"emulator",
"NES",
"Famicom",
"Atari 2600",
"Atari VCS",
"Atari 7800",
"Atari 8-bit",
"Commodore 64",
"C64",
"VIC-20",
"ColecoVision",
"MSX",
"ZX Spectrum",
"Apple II",
"Game Boy",
"Sega Master System",
"Z80",
"6809",
"ca65",
"dasm",
"homebrew",
"game development",
"Verilog",
"HDL",
"hardware design",
"retrogaming"
],
"version": "0.1.2",
"publisher": "8bitworkshop",
"icon": "images/icon.png",
"galleryBanner": {
"color": "#0d0d3b",
"theme": "dark"
},
"preview": true,
"license": "GPL-3.0-only",
"repository": {
"type": "git",
"url": "https://github.com/8bitworkshop/8bitworkshop.git",
"directory": "extension"
},
"bugs": {
"url": "https://github.com/8bitworkshop/8bitworkshop/issues"
},
"homepage": "https://8bitworkshop.com",
"engines": {
"vscode": "^1.90.0"
},
"categories": [
"Programming Languages",
"Debuggers"
],
"main": "./out/extension.js",
"activationEvents": [
"onStartupFinished"
],
"contributes": {
"commands": [
{
"command": "8bitworkshop.newProject",
"title": "New Project...",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.openExample",
"title": "Open Example",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.copyToWorkspace",
"title": "Copy to Workspace",
"category": "8bitworkshop",
"icon": "$(copy)"
},
{
"command": "8bitworkshop.downloadToolchains",
"title": "Download All Toolchains",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.build",
"title": "Build",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.run",
"title": "Run",
"category": "8bitworkshop",
"icon": "$(play)"
},
{
"command": "8bitworkshop.debug",
"title": "Debug",
"category": "8bitworkshop",
"icon": "$(debug-alt)"
},
{
"command": "8bitworkshop.runThisFile",
"title": "Run This File",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.runMainFile",
"title": "Run Main File",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.followActiveEditor",
"title": "Follow Active Editor",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.setMainFile",
"title": "Set as Main File",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.changeMainFile",
"title": "Change Main File...",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.selectPlatform",
"title": "Change Platform...",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.detectProjects",
"title": "Detect Projects",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.removeProject",
"title": "Remove Project...",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.addLaunchConfiguration",
"title": "Add Launch Configuration",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.projectMenu",
"title": "Project Options",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.reset",
"title": "Reset Emulator",
"category": "8bitworkshop",
"icon": "$(debug-restart)"
},
{
"command": "8bitworkshop.pause",
"title": "Pause Emulator",
"category": "8bitworkshop",
"icon": "$(debug-pause)"
},
{
"command": "8bitworkshop.resume",
"title": "Resume Emulator",
"category": "8bitworkshop",
"icon": "$(debug-continue)"
},
{
"command": "8bitworkshop.stop",
"title": "Stop Emulator",
"category": "8bitworkshop",
"icon": "$(debug-stop)"
},
{
"command": "8bitworkshop.mute",
"title": "Mute Emulator",
"category": "8bitworkshop",
"icon": "$(mute)"
},
{
"command": "8bitworkshop.unmute",
"title": "Unmute Emulator",
"category": "8bitworkshop",
"icon": "$(unmute)"
},
{
"command": "8bitworkshop.showMachine",
"title": "Show Machine View",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.recordVcd",
"title": "Record Signals to VCD...",
"category": "8bitworkshop"
},
{
"command": "8bitworkshop.stopVcd",
"title": "Stop Recording VCD",
"category": "8bitworkshop"
}
],
"viewsContainers": {
"panel": [
{
"id": "8bitworkshop",
"title": "8bitworkshop",
"icon": "images/panel.svg"
}
]
},
"views": {
"8bitworkshop": [
{
"type": "webview",
"id": "8bitworkshop.machine",
"name": "Machine",
"when": "8bitworkshop.hasDebugInfo"
},
{
"type": "webview",
"id": "8bitworkshop.waveform",
"name": "Waveform",
"when": "8bitworkshop.hasWaveform"
}
]
},
"languageModelTools": [
{
"name": "8bitworkshop_build",
"displayName": "Build 8bitworkshop Program",
"toolReferenceName": "8bitworkshopBuild",
"canBeReferencedInPrompt": true,
"icon": "$(tools)",
"userDescription": "Build an 8bitworkshop program and report its errors.",
"modelDescription": "Compile a retro game or program (C, assembly, BASIC, and more, for consoles and computers such as the NES, Atari 2600, C64, and Game Boy) with 8bitworkshop's toolchains. Uses unsaved editor contents and the project's platform and build tool. Returns the ROM size, or each error as file:line: message. The errors also appear in the Problems panel.",
"tags": [
"8bitworkshop",
"build"
],
"inputSchema": {
"type": "object",
"properties": {
"file": {
"type": "string",
"description": "Path of the source file, absolute or relative to the workspace folder. In a project, any of its files builds the project's program. Omit to use the program in the active editor."
},
"platform": {
"type": "string",
"description": "Platform id, such as nes, c64, vcs, or sms. Needed only for a file outside an 8bitworkshop project; a project's own platform is used otherwise."
}
}
}
},
{
"name": "8bitworkshop_run",
"displayName": "Run 8bitworkshop Program",
"toolReferenceName": "8bitworkshopRun",
"canBeReferencedInPrompt": true,
"icon": "$(play)",
"userDescription": "Build an 8bitworkshop program, run it in a hidden emulator, and return a screenshot.",
"modelDescription": "Build an 8bitworkshop program, run it in a hidden emulator (not the user's emulator panel), and return a PNG screenshot of the last frame, plus any script output. Use it to check that a program starts, draws what you expect, or reaches a routine. If the build fails, returns the errors instead. The script is a list of commands separated by ';' or newlines, with symbol names from the build allowed as addresses: 'run N' advances N frames; 'key KEY' presses a key (a character, ENTER, SPACE, UP/DOWN/LEFT/RIGHT, F1...); 'break ADDR [MAXFRAMES]' runs until PC reaches ADDR (such as main); 'step [N]' and 'over [N]' step instructions or source lines; 'mem START [LEN]' hexdumps memory; 'pc [N]' disassembles at PC; 'screen [START] [COLS] [ROWS]' decodes text screen RAM; 'hist [N]' shows recently executed instructions; 'info' prints machine state; 'reset' resets. Example: 'run 60; key SPACE; run 30; mem score 2'.",
"tags": [
"8bitworkshop",
"emulator",
"screenshot"
],
"inputSchema": {
"type": "object",
"properties": {
"file": {
"type": "string",
"description": "Path of the source file, absolute or relative to the workspace folder. In a project, any of its files builds the project's program. Omit to use the program in the active editor."
},
"platform": {
"type": "string",
"description": "Platform id, such as nes, c64, vcs, or sms. Needed only for a file outside an 8bitworkshop project; a project's own platform is used otherwise."
},
"frames": {
"type": "integer",
"minimum": 1,
"description": "Frames to run before the script (60 is about one second). Without frames or script, runs 60 frames."
},
"script": {
"type": "string",
"description": "Commands to run after the frames, such as 'run 60; key SPACE; run 30; mem score 2'."
}
}
}
}
],
"configuration": {
"title": "8bitworkshop",
"properties": {
"8bitworkshop.platform": {
"type": "string",
"default": "",
"scope": "resource",
"description": "Target platform id (e.g. c64, nes, vcs, gb).",
"markdownDescription": "Target platform id (`nes`, `c64`, `vcs`, ...). Set by New Project, Set as Main File, or detection."
},
"8bitworkshop.mainFile": {
"type": "string",
"default": "",
"scope": "resource",
"description": "Main source file, relative to the workspace folder. Leave empty to run whichever program is open."
},
"8bitworkshop.tool": {
"type": "string",
"default": "",
"scope": "resource",
"description": "Tool for the main file, when it isn't the platform's usual tool for the extension (ca65 for a .asm file, say)."
},
"8bitworkshop.folders": {
"type": "object",
"default": {},
"scope": "resource",
"markdownDescription": "Projects in subdirectories: directory (relative to the workspace folder) → `{ \"platform\", \"mainFile\", \"tool\" }`. The most specific directory wins.",
"additionalProperties": {
"type": "object",
"properties": {
"platform": {
"type": "string"
},
"mainFile": {
"type": "string"
},
"tool": {
"type": "string"
}
},
"required": [
"platform"
]
}
},
"8bitworkshop.vectorSize": {
"type": "number",
"default": 512,
"minimum": 128,
"maximum": 2048,
"scope": "window",
"markdownDescription": "Pixels along the longer side of the screen for vector platforms (`vector`, `vectrex`). Takes effect on the next run."
},
"8bitworkshop.autoBuild": {
"type": "string",
"enum": [
"onType",
"onSave",
"off"
],
"default": "onType",
"enumDescriptions": [
"Build as you type, after a short pause.",
"Build when you save.",
"Build only with the Build command."
],
"markdownDescription": "When to build. Tools that build on a server (llvm-mos) always wait for a save."
},
"8bitworkshop.reloadOnBuild": {
"type": "string",
"enum": [
"always",
"onSave",
"never"
],
"default": "always",
"enumDescriptions": [
"Restart the game after each successful build.",
"Restart it only when you save; typing still updates errors.",
"Keep the running game until you Run again."
],
"markdownDescription": "When a successful build restarts the running game."
},
"8bitworkshop.terminalCommand": {
"type": "boolean",
"default": false,
"markdownDescription": "Add the `8bws` command to the integrated terminal, to build and run programs from the command line or an AI agent. Open a new terminal after changing this."
},
"8bitworkshop.exportRom": {
"type": "boolean",
"default": false,
"scope": "resource",
"description": "Write each successful build's ROM to the export folder."
},
"8bitworkshop.exportRomPath": {
"type": "string",
"default": "bin",
"scope": "resource",
"description": "Folder for exported ROMs, relative to the main file's directory."
},
"8bitworkshop.toolchainPath": {
"type": "string",
"default": "",
"description": "Directory containing src/worker (toolchain assets), such as an 8bitworkshop checkout. When empty, toolchains download on first use.",
"scope": "machine"
}
}
},
"languages": [
{
"id": "8bws-6502",
"aliases": [
"6502 Assembly",
"6502"
],
"extensions": [
".dasm",
".ca65",
".xa",
".nesasm",
".acme"
],
"configuration": "./out/syntaxes/8bws-6502.language-configuration.json"
},
{
"id": "8bws-z80",
"aliases": [
"Z80 Assembly",
"Z80"
],
"extensions": [
".zmac",
".sgb"
],
"configuration": "./out/syntaxes/8bws-z80.language-configuration.json"
},
{
"id": "8bws-6809",
"aliases": [
"6809 Assembly",
"6809"
],
"extensions": [
".xasm",
".lwasm"
],
"configuration": "./out/syntaxes/8bws-6809.language-configuration.json"
},
{
"id": "8bws-verilog",
"aliases": [
"Verilog (8bitworkshop)"
],
"configuration": "./out/syntaxes/8bws-verilog.language-configuration.json"
}
],
"grammars": [
{
"language": "8bws-6502",
"scopeName": "source.asm.6502",
"path": "./out/syntaxes/8bws-6502.tmLanguage.json"
},
{
"language": "8bws-z80",
"scopeName": "source.asm.z80",
"path": "./out/syntaxes/8bws-z80.tmLanguage.json"
},
{
"language": "8bws-6809",
"scopeName": "source.asm.6809",
"path": "./out/syntaxes/8bws-6809.tmLanguage.json"
},
{
"language": "8bws-verilog",
"scopeName": "source.verilog.8bws",
"path": "./out/syntaxes/8bws-verilog.tmLanguage.json"
}
],
"menus": {
"editor/title": [
{
"command": "8bitworkshop.run",
"when": "8bitworkshop.canRun && activeWebviewPanelId != '8bitworkshop.emulator'",
"group": "navigation"
},
{
"command": "8bitworkshop.debug",
"when": "8bitworkshop.canRun && activeWebviewPanelId != '8bitworkshop.emulator' && !inDebugMode",
"group": "navigation"
},
{
"command": "8bitworkshop.copyToWorkspace",
"when": "resourceScheme == 8bws-preset",
"group": "navigation@0"
},
{
"command": "8bitworkshop.pause",
"when": "activeWebviewPanelId == '8bitworkshop.emulator' && 8bitworkshop.emuRunning",
"group": "navigation@1"
},
{
"command": "8bitworkshop.resume",
"when": "activeWebviewPanelId == '8bitworkshop.emulator' && !8bitworkshop.emuRunning",
"group": "navigation@1"
},
{
"command": "8bitworkshop.reset",
"when": "activeWebviewPanelId == '8bitworkshop.emulator'",
"group": "navigation@2"
},
{
"command": "8bitworkshop.stop",
"when": "activeWebviewPanelId == '8bitworkshop.emulator'",
"group": "navigation@3"
},
{
"command": "8bitworkshop.mute",
"when": "activeWebviewPanelId == '8bitworkshop.emulator' && !8bitworkshop.muted",
"group": "navigation@0"
},
{
"command": "8bitworkshop.unmute",
"when": "activeWebviewPanelId == '8bitworkshop.emulator' && 8bitworkshop.muted",
"group": "navigation@0"
},
{
"command": "8bitworkshop.runThisFile",
"when": "8bitworkshop.canRun",
"group": "8bitworkshop@1"
}
],
"editor/context": [
{
"command": "8bitworkshop.setMainFile",
"when": "resourceScheme == file",
"group": "8bitworkshop@1"
}
],
"explorer/context": [
{
"command": "8bitworkshop.setMainFile",
"when": "!explorerResourceIsFolder",
"group": "8bitworkshop@1"
}
],
"commandPalette": [
{
"command": "8bitworkshop.downloadToolchains",
"when": "8bitworkshop.canDownloadToolchains"
},
{
"command": "8bitworkshop.copyToWorkspace",
"when": "resourceScheme == 8bws-preset"
},
{
"command": "8bitworkshop.removeProject",
"when": "8bitworkshop.canRun"
},
{
"command": "8bitworkshop.pause",
"when": "8bitworkshop.emuRunning"
},
{
"command": "8bitworkshop.resume",
"when": "8bitworkshop.emuOpen && !8bitworkshop.emuRunning"
},
{
"command": "8bitworkshop.reset",
"when": "8bitworkshop.emuOpen"
},
{
"command": "8bitworkshop.stop",
"when": "8bitworkshop.emuOpen"
},
{
"command": "8bitworkshop.mute",
"when": "8bitworkshop.emuOpen && !8bitworkshop.muted"
},
{
"command": "8bitworkshop.unmute",
"when": "8bitworkshop.emuOpen && 8bitworkshop.muted"
},
{
"command": "8bitworkshop.showMachine",
"when": "8bitworkshop.hasDebugInfo"
},
{
"command": "8bitworkshop.recordVcd",
"when": "8bitworkshop.canRecordVcd && !8bitworkshop.recordingVcd"
},
{
"command": "8bitworkshop.stopVcd",
"when": "8bitworkshop.recordingVcd"
}
]
},
"viewsWelcome": [
{
"view": "explorer",
"contents": "Make a program for a classic console or computer.\n[New 8bitworkshop Project](command:8bitworkshop.newProject)\n[Open 8bitworkshop Example](command:8bitworkshop.openExample)"
}
],
"breakpoints": [
{ "language": "c" },
{ "language": "cpp" },
{ "language": "8bws-6502" },
{ "language": "8bws-z80" },
{ "language": "8bws-6809" }
],
"debuggers": [
{
"type": "8bitworkshop",
"label": "8bitworkshop",
"languages": [],
"configurationAttributes": {
"launch": {
"properties": {
"platform": {
"type": "string",
"description": "Platform id (nes, c64, ...). Defaults to the project's."
},
"mainFile": {
"type": "string",
"description": "The program to run, relative to the workspace folder."
},
"tool": {
"type": "string",
"description": "Tool for the main file, if not the usual one."
},
"stopOnEntry": {
"type": "boolean",
"description": "Stop before the program's first instruction instead of running.",
"default": false
},
"script": {
"type": "string",
"description": "Commands to run once the program is loaded, as in the Debug Console (e.g. \"break main; key SPACE\")."
}
}
}
},
"configurationSnippets": [
{
"label": "8bitworkshop: Run a program",
"body": {
"type": "8bitworkshop",
"request": "launch",
"name": "Run ${1:main.c}",
"mainFile": "${1:main.c}"
}
}
]
}
]
},
"scripts": {
"build": "node scripts/build.mjs && node out/presetindex.js && node out/syntaxes.js",
"watch": "node scripts/build.mjs --watch",
"typecheck": "tsc --noEmit -p .",
"assets": "node scripts/build.mjs && node out/assetpack.js --quality 9",
"assets-quick": "node scripts/build.mjs && node out/assetpack.js --quality 8",
"test": "npm run build && mocha --timeout 60000 out/test/*.test.js",
"npm-package": "npm run assets-quick && node scripts/stage-npm.mjs",
"vscode:prepublish": "npm run build",
"package": "npm run assets-quick && vsce package --no-dependencies",
"package:release": "npm run assets && vsce package --no-dependencies",
"vsce-publish": "npm run assets && vsce publish --no-dependencies",
"ovsx-publish": "npm run package:release && npx ovsx publish $npm_package_name-$npm_package_version.vsix"
},
"devDependencies": {
"@types/vscode": "~1.90.0",
"@vscode/vsce": "^4.0.0",
"vscode-oniguruma": "^2.0.1",
"vscode-textmate": "^9.3.2"
},
"capabilities": {
"untrustedWorkspaces": {
"supported": "limited",
"description": "Builds and emulation run sandboxed. 8bitworkshop.toolchainPath is ignored, since it loads code.",
"restrictedConfigurations": [
"8bitworkshop.toolchainPath"
]
}
}
}