Skip to content

Commit

Permalink
Add VS Code configs
Browse files Browse the repository at this point in the history
  • Loading branch information
KyleKotowick committed Oct 27, 2024
1 parent 853cb16 commit 22a3635
Show file tree
Hide file tree
Showing 3 changed files with 75 additions and 2 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,3 @@ utils/nrf-builder/provisioner-nk3am-nrf52-1.2.2.bin
utils/nrf-builder/provisioner-nk3am-nrf52-1.2.2.hex
utils/nrf-builder/provisioner-nk3am-nrf52-1.2.2.zip
utils/nrf-builder/test-certs/

.vscode/
33 changes: 33 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "lldb",
"request": "launch",
"name": "USB/IP Emulator",
"cargo": {
"args": [
"build",
"--features",
"provisioner,backend-dilithium2,backend-dilithium3,backend-dilithium5",
"--bin=usbip-runner",
],
"filter": {
"kind": "bin",
}
},
"preLaunchTask": "DelayedUSBIPAttach",
"program": "${cargo:program}",
"args": [
// "--ifs",
// "${userHome}/nitrokey-usbip-ifs",
"--user-presence",
"interactive"
],
"cwd": "${workspaceFolder}/runners/usbip",
}
],
}
42 changes: 42 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"version": "2.0.0",
"tasks": [
{
// This task waits for a few seconds before attaching
// the newly-created USB/IP adapter
"label": "DelayedUSBIPAttach",
"type": "shell",
"command": "sudo",
"args": [
"${workspaceFolder}/runners/usbip/delayed-attach.sh"
],
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": true,
"clear": true
},
// All this is needed so VSCode just lets this task run in the background.
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
],
},
],
}

0 comments on commit 22a3635

Please sign in to comment.