Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 1 | // Note: VS Code's setting precedence is `.vscode/` > `cts.code-workspace` > global user settings. |
| 2 | { |
Kai Ninomiya | 497f285 | 2020-11-17 18:47:48 -0800 | [diff] [blame] | 3 | "folders": [ |
| 4 | { |
| 5 | "name": "cts", |
| 6 | "path": "." |
| 7 | }, |
| 8 | { |
| 9 | "name": "webgpu", |
| 10 | "path": "src/webgpu" |
| 11 | } |
| 12 | ], |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 13 | "settings": { |
| 14 | "editor.defaultFormatter": "esbenp.prettier-vscode", |
| 15 | "editor.detectIndentation": false, |
| 16 | "editor.rulers": [100], |
| 17 | "editor.tabSize": 2, |
| 18 | "files.insertFinalNewline": true, |
| 19 | "files.trimFinalNewlines": true, |
| 20 | "files.trimTrailingWhitespace": true, |
| 21 | "files.exclude": { |
| 22 | "*.tmp.txt": true, |
| 23 | ".gitignore": true, |
| 24 | ".travis.yml": true, |
| 25 | ".tscache": true, |
| 26 | "deploy_key.enc": true, |
| 27 | "node_modules": true, |
| 28 | "out": true, |
Kai Ninomiya | d40a30f | 2021-06-08 18:10:59 -0700 | [diff] [blame] | 29 | "out-node": true, |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 30 | "out-wpt": true, |
Kai Ninomiya | d40a30f | 2021-06-08 18:10:59 -0700 | [diff] [blame] | 31 | "docs/tsdoc": true, |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 32 | "package-lock.json": true |
| 33 | }, |
| 34 | // Configure VSCode to use the right style when automatically adding imports on autocomplete. |
| 35 | "typescript.preferences.importModuleSpecifier": "relative", |
| 36 | "typescript.preferences.importModuleSpecifierEnding": "js", |
| 37 | "typescript.preferences.quoteStyle": "single" |
| 38 | }, |
| 39 | "tasks": { |
| 40 | "version": "2.0.0", |
| 41 | "tasks": [ |
Kai Ninomiya | 971207d | 2020-11-17 19:30:48 -0800 | [diff] [blame] | 42 | // Only supports "shell" and "process" tasks. |
| 43 | // https://code.visualstudio.com/docs/editor/multi-root-workspaces#_workspace-task-configuration |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 44 | { |
Kai Ninomiya | 971207d | 2020-11-17 19:30:48 -0800 | [diff] [blame] | 45 | // Use "group": "build" instead of "test" so it's easy to access from cmd-shift-B. |
| 46 | "group": "build", |
| 47 | "label": "npm: test", |
| 48 | "detail": "Run all presubmit checks", |
| 49 | |
| 50 | "type": "shell", |
| 51 | "command": "npm run test", |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 52 | "problemMatcher": [] |
| 53 | }, |
| 54 | { |
Kai Ninomiya | 971207d | 2020-11-17 19:30:48 -0800 | [diff] [blame] | 55 | "group": "build", |
| 56 | "label": "npm: check", |
| 57 | "detail": "Just typecheck", |
| 58 | |
| 59 | "type": "shell", |
| 60 | "command": "npm run check", |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 61 | "problemMatcher": ["$tsc"] |
Kai Ninomiya | 971207d | 2020-11-17 19:30:48 -0800 | [diff] [blame] | 62 | }, |
| 63 | { |
| 64 | "group": "build", |
| 65 | "label": "npm: standalone", |
| 66 | "detail": "Build standalone and typecheck", |
| 67 | |
| 68 | "type": "shell", |
| 69 | "command": "npm run standalone", |
| 70 | "problemMatcher": [] |
| 71 | }, |
| 72 | { |
| 73 | "group": "build", |
| 74 | "label": "npm: wpt", |
| 75 | "detail": "Build for WPT and typecheck", |
| 76 | |
| 77 | "type": "shell", |
| 78 | "command": "npm run wpt", |
| 79 | "problemMatcher": [] |
| 80 | }, |
| 81 | { |
| 82 | "group": "build", |
| 83 | "label": "npm: unittest", |
| 84 | "detail": "Build standalone, typecheck, and unittest", |
| 85 | |
| 86 | "type": "shell", |
| 87 | "command": "npm run unittest", |
| 88 | "problemMatcher": [] |
| 89 | }, |
Kai Ninomiya | d40a30f | 2021-06-08 18:10:59 -0700 | [diff] [blame] | 90 | { |
| 91 | "group": "build", |
| 92 | "label": "npm: tsdoc", |
| 93 | "detail": "Build docs/tsdoc/", |
| 94 | |
| 95 | "type": "shell", |
| 96 | "command": "npm run tsdoc", |
| 97 | "problemMatcher": [] |
| 98 | }, |
Kai Ninomiya | 7c40d21 | 2022-01-04 14:25:02 -0800 | [diff] [blame] | 99 | { |
| 100 | "group": "build", |
| 101 | "label": "grunt: run:lint", |
| 102 | "detail": "Run eslint", |
| 103 | |
| 104 | "type": "shell", |
| 105 | "command": "npx grunt run:lint", |
| 106 | "problemMatcher": ["$eslint-stylish"] |
| 107 | }, |
Kai Ninomiya | dab51c7 | 2020-09-28 18:09:29 -0700 | [diff] [blame] | 108 | ] |
| 109 | } |
| 110 | } |