|
| 1 | +{ |
| 2 | + "name": "STeaMi MicroPython Dev", |
| 3 | + "build": { |
| 4 | + "dockerfile": "Dockerfile" |
| 5 | + }, |
| 6 | + |
| 7 | + // USB access for STeaMi board (DAPLink / mpremote / OpenOCD). |
| 8 | + // Privileged mode is required for firmware flashing and board communication. |
| 9 | + // This is incompatible with GitHub Codespaces but essential for local use. |
| 10 | + "privileged": true, |
| 11 | + "mounts": ["type=bind,source=/dev/bus/usb,target=/dev/bus/usb"], |
| 12 | + "runArgs": ["--device=/dev/bus/usb"], |
| 13 | + |
| 14 | + "remoteEnv": { |
| 15 | + "VENV_DIR": "/home/vscode/.venv" |
| 16 | + }, |
| 17 | + |
| 18 | + "features": { |
| 19 | + "ghcr.io/devcontainers/features/node:1": { |
| 20 | + "version": "22" |
| 21 | + }, |
| 22 | + "ghcr.io/devcontainers/features/common-utils:2": { |
| 23 | + "installZsh": true, |
| 24 | + "installOhMyZsh": true, |
| 25 | + "upgradePackages": true, |
| 26 | + "username": "vscode" |
| 27 | + }, |
| 28 | + "ghcr.io/devcontainers/features/github-cli:1": {}, |
| 29 | + "ghcr.io/stuartleeks/dev-container-features/shell-history:0": {} |
| 30 | + }, |
| 31 | + |
| 32 | + "customizations": { |
| 33 | + "vscode": { |
| 34 | + "settings": { |
| 35 | + "terminal.integrated.profiles.linux": { |
| 36 | + "zsh": { |
| 37 | + "path": "zsh" |
| 38 | + } |
| 39 | + }, |
| 40 | + "terminal.integrated.defaultProfile.linux": "zsh", |
| 41 | + |
| 42 | + "editor.minimap.enabled": false, |
| 43 | + "editor.formatOnSave": true, |
| 44 | + "editor.formatOnPaste": true, |
| 45 | + "editor.rulers": [99], |
| 46 | + |
| 47 | + "[python]": { |
| 48 | + "editor.defaultFormatter": "charliermarsh.ruff" |
| 49 | + }, |
| 50 | + "[json]": { |
| 51 | + "editor.defaultFormatter": "esbenp.prettier-vscode" |
| 52 | + }, |
| 53 | + "[jsonc]": { |
| 54 | + "editor.defaultFormatter": "esbenp.prettier-vscode" |
| 55 | + }, |
| 56 | + "[makefile]": { |
| 57 | + "editor.tabSize": 8 |
| 58 | + }, |
| 59 | + "[yaml]": { |
| 60 | + "editor.tabSize": 2 |
| 61 | + }, |
| 62 | + |
| 63 | + "python.defaultInterpreterPath": "/home/vscode/.venv/bin/python", |
| 64 | + "python.testing.pytestEnabled": true, |
| 65 | + "python.testing.pytestArgs": ["-v", "-k", "mock"], |
| 66 | + |
| 67 | + "files.watcherExclude": { |
| 68 | + "**/.git/objects/**": true, |
| 69 | + "**/node_modules/**": true, |
| 70 | + "**/.build/**": true, |
| 71 | + "**/__pycache__/**": true |
| 72 | + }, |
| 73 | + "search.exclude": { |
| 74 | + "**/node_modules": true, |
| 75 | + "**/.build": true |
| 76 | + } |
| 77 | + }, |
| 78 | + "extensions": [ |
| 79 | + "charliermarsh.ruff", |
| 80 | + "ms-python.python", |
| 81 | + "ms-python.vscode-pylance", |
| 82 | + "ms-vscode.vscode-serial-monitor", |
| 83 | + "esbenp.prettier-vscode", |
| 84 | + "github.vscode-pull-request-github", |
| 85 | + "vivaxy.vscode-conventional-commits" |
| 86 | + ] |
| 87 | + } |
| 88 | + }, |
| 89 | + |
| 90 | + "postCreateCommand": "make setup VENV_DIR=/home/vscode/.venv && sudo /usr/lib/systemd/systemd-udevd --daemon", |
| 91 | + "remoteUser": "vscode" |
| 92 | +} |
0 commit comments