| 1 | { |
| 2 | "version": "2.0.0", |
| 3 | "tasks": [ |
| 4 | { |
| 5 | "label": "tsc:watch", |
| 6 | "type": "npm", |
| 7 | "script": "tsc:watch", |
| 8 | "isBackground": true, |
| 9 | "problemMatcher": ["$tsc-watch"], |
| 10 | "group": { |
| 11 | "kind": "build", |
| 12 | "isDefault": true |
| 13 | }, |
| 14 | "presentation": { |
| 15 | "reveal": "always", |
| 16 | "panel": "new" |
| 17 | } |
| 18 | }, |
| 19 | // Compile and bundle the extension |
| 20 | { |
| 21 | "label": "vscode-extension:build", |
| 22 | "dependsOn": [ |
| 23 | // TSC type checking |
| 24 | "tsc:watch", |
| 25 | // To build the React app that is used in the extension |
| 26 | "vscode-extension:continue-ui:build", |
| 27 | // // To bundle the code the same way we do for publishing |
| 28 | "vscode-extension:esbuild", |
| 29 | // To ensure extension.js is regenerated even if |
| 30 | // vscode-extension:esbuild was already running in background |
| 31 | "vscode-extension:esbuild-notify", |
| 32 | // Start the React app that is used in the extension |
| 33 | "gui:dev" |
| 34 | ], |
| 35 | "group": { |
| 36 | "kind": "build", |
| 37 | "isDefault": true |
| 38 | } |
| 39 | }, |
| 40 | { |
| 41 | "label": "vscode-extension:esbuild-notify", |
| 42 | "dependsOn": ["vscode-extension:esbuild"], |
| 43 | "type": "npm", |
| 44 | "script": "esbuild-notify", |
| 45 | "path": "extensions/vscode" |
| 46 | }, |
| 47 | { |
| 48 | "label": "vscode-extension:esbuild", |
| 49 | "dependsOn": ["vscode-extension:continue-ui:build"], |
| 50 | "type": "npm", |
| 51 | "script": "esbuild-watch", |
| 52 | "path": "extensions/vscode", |
| 53 | "isBackground": true, |
| 54 | "problemMatcher": [ |
| 55 | { |
| 56 | "pattern": [ |
| 57 | { |
| 58 | "regexp": "> (.*?):([0-9]+):([0-9]+): (warning|error): (.+)$", |
| 59 | "file": 1, |
| 60 | "line": 2, |
| 61 | "column": 3, |
| 62 | "severity": 4, |
| 63 | "message": 5 |
| 64 | } |
| 65 | ], |
| 66 | "background": { |
| 67 | "activeOnStart": true, |
| 68 | "beginsPattern": ">", |
| 69 | "endsPattern": "VS Code Extension esbuild complete" |
| 70 | } |
| 71 | } |
| 72 | ] |
| 73 | }, |
| 74 | { |
| 75 | "label": "vscode-extension:package", |
| 76 | "dependsOn": ["vscode-extension:esbuild"], |
| 77 | "type": "npm", |
| 78 | "script": "package", |
| 79 | "path": "extensions/vscode", |
| 80 | "problemMatcher": [ |
| 81 | { |
| 82 | "pattern": [ |
| 83 | { |
| 84 | "regexp": "> (.*?):([0-9]+):([0-9]+): (warning|error): (.+)$", |
| 85 | "file": 1, |
| 86 | "line": 2, |
| 87 | "column": 3, |
| 88 | "severity": 4, |
| 89 | "message": 5 |
| 90 | } |
| 91 | ] |
| 92 | } |
| 93 | ] |
| 94 | }, |
| 95 | { |
| 96 | "label": "vscode-extension:continue-ui:build", |
| 97 | "type": "shell", |
| 98 | "command": "node", |
| 99 | "args": ["${workspaceFolder}/extensions/vscode/scripts/prepackage.js"], |
| 100 | "problemMatcher": ["$tsc"], |
| 101 | "presentation": { |
| 102 | "revealProblems": "onProblem", |
| 103 | "clear": true |
| 104 | }, |
| 105 | "options": { |
| 106 | "cwd": "${workspaceFolder}/extensions/vscode" |
| 107 | } |
| 108 | }, |
| 109 | // |
| 110 | // Compile and bundle tests |
| 111 | { |
| 112 | "label": "vscode-extension:tests:build", |
| 113 | "dependsOn": [ |
| 114 | // Build the extension |
| 115 | "vscode-extension:build", |
| 116 | // To detect compile errors - this type checks both the extension and the tests |
| 117 | "tsc:watch", |
| 118 | "vscode-extension:tests:esbuild" |
| 119 | ] |
| 120 | }, |
| 121 | { |
| 122 | "label": "vscode-extension:tests:esbuild", |
| 123 | "type": "npm", |
| 124 | "script": "build-test", |
| 125 | "path": "extensions/vscode", |
| 126 | "problemMatcher": [ |
| 127 | { |
| 128 | "pattern": [ |
| 129 | { |
| 130 | "regexp": "> (.*?):([0-9]+):([0-9]+): (warning|error): (.+)$", |
| 131 | "file": 1, |
| 132 | "line": 2, |
| 133 | "column": 3, |
| 134 | "severity": 4, |
| 135 | "message": 5 |
| 136 | } |
| 137 | ] |
| 138 | } |
| 139 | ] |
| 140 | }, |
| 141 | // |
| 142 | // Install or update all dependencies for all projects in the monrepo |
| 143 | { |
| 144 | "label": "install-all-dependencies", |
| 145 | "type": "shell", |
| 146 | "windows": { "command": "./scripts/install-dependencies.ps1" }, |
| 147 | "command": "./scripts/install-dependencies.sh", |
| 148 | "problemMatcher": [] // Empty so users are not prompted to select progress reporting |
| 149 | }, |
| 150 | // |
| 151 | // Start the React App for debugging with Vite |
| 152 | { |
| 153 | "label": "gui:dev", |
| 154 | "type": "shell", |
| 155 | "command": "npm", |
| 156 | "options": { |
| 157 | "cwd": "${workspaceFolder}/gui" |
| 158 | }, |
| 159 | "args": ["run", "dev"], |
| 160 | "isBackground": true, |
| 161 | "problemMatcher": [ |
| 162 | { |
| 163 | "pattern": [ |
| 164 | { |
| 165 | "regexp": ".", |
| 166 | "file": 1, |
| 167 | "location": 2, |
| 168 | "message": 3 |
| 169 | } |
| 170 | ], |
| 171 | "background": { |
| 172 | "activeOnStart": true, |
| 173 | "beginsPattern": ".", |
| 174 | "endsPattern": "." |
| 175 | } |
| 176 | } |
| 177 | ] |
| 178 | }, |
| 179 | // |
| 180 | // esbuild for the core binary |
| 181 | { |
| 182 | "label": "binary:esbuild", |
| 183 | "type": "shell", |
| 184 | "command": "npm", |
| 185 | "args": ["run", "esbuild"], |
| 186 | "problemMatcher": [], |
| 187 | "options": { |
| 188 | "cwd": "binary" |
| 189 | } |
| 190 | }, |
| 191 | { |
| 192 | "label": "docs:start", |
| 193 | "type": "shell", |
| 194 | "command": "npm", |
| 195 | "args": ["run", "start", "--", "--no-open"], |
| 196 | "problemMatcher": [], |
| 197 | "options": { |
| 198 | "cwd": "docs" |
| 199 | } |
| 200 | }, |
| 201 | { |
| 202 | "label": "clean", |
| 203 | "type": "shell", |
| 204 | "command": "node", |
| 205 | "args": ["${workspaceFolder}/scripts/uninstall.js"], |
| 206 | "problemMatcher": [] |
| 207 | }, |
| 208 | { |
| 209 | "label": "refresh-dependencies:core", |
| 210 | "type": "shell", |
| 211 | "command": "npm", |
| 212 | "args": ["install"], |
| 213 | "problemMatcher": [], |
| 214 | "options": { |
| 215 | "cwd": "${workspaceFolder}/core" |
| 216 | }, |
| 217 | "presentation": { |
| 218 | "close": true |
| 219 | } |
| 220 | }, |
| 221 | { |
| 222 | "label": "refresh-dependencies:vscode", |
| 223 | "type": "shell", |
| 224 | "command": "npm", |
| 225 | "args": ["install"], |
| 226 | "problemMatcher": [], |
| 227 | "options": { |
| 228 | "cwd": "${workspaceFolder}/extensions/vscode" |
| 229 | }, |
| 230 | "presentation": { |
| 231 | "close": true |
| 232 | } |
| 233 | }, |
| 234 | { |
| 235 | "label": "refresh-dependencies:gui", |
| 236 | "type": "shell", |
| 237 | "command": "npm", |
| 238 | "args": ["install"], |
| 239 | "problemMatcher": [], |
| 240 | "options": { |
| 241 | "cwd": "${workspaceFolder}/gui" |
| 242 | }, |
| 243 | "presentation": { |
| 244 | "close": true |
| 245 | } |
| 246 | }, |
| 247 | { |
| 248 | "label": "refresh-dependencies:all", |
| 249 | "dependsOn": [ |
| 250 | "refresh-dependencies:core", |
| 251 | "refresh-dependencies:gui", |
| 252 | "refresh-dependencies:vscode" |
| 253 | ], |
| 254 | "type": "shell", |
| 255 | "problemMatcher": [] |
| 256 | } |
| 257 | ] |
| 258 | } |