Skip to content

Commit 36608db

Browse files
feat: use basename var in vscode debug (fspoettel#69)
removes the need to specify the current day in `launch.json`
1 parent a50047a commit 36608db

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.vscode/launch.json

+8-4
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@
1212
"args": [
1313
"test",
1414
"--no-run",
15-
// replace `01` here with the solution you like to debug.
16-
"--bin=01",
15+
// replace with binary name (e.g. "01") here if you always
16+
// want to debug one file regardless of the active file in
17+
// the editor.
18+
"--bin=${fileBasenameNoExtension}",
1719
"--package=advent_of_code"
1820
],
1921
},
@@ -27,8 +29,10 @@
2729
"cargo": {
2830
"args": [
2931
"build",
30-
// replace `01` here with the solution you like to debug.
31-
"--bin=01",
32+
// replace with binary name (e.g. "01") here if you always
33+
// want to debug one file regardless of the active file in
34+
// the editor
35+
"--bin=${fileBasenameNoExtension}",
3236
"--package=advent_of_code"
3337
],
3438
},

0 commit comments

Comments
 (0)