-
I have a git repo with a src folder which contains my Go module (go.mod, main.go, ...). Inside the root folder there is another folder "run" which contains a "workdir" folder which contains config files to run the application in dev mode. It looks like this:
I want to debug the program/module in src but the binary should be run inside run/workdir, because it uses the binary path to find the configs. In VS Code I can do that with the following launch.json:
It was working a few days ago, but I cannot remember what cli arguments I used. I thought it was like this:
But the paths the program uses are not correct. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
That's the correct option, what does it mean that "the paths the program uses are not correct"? |
Beta Was this translation helpful? Give feedback.
Yes,
--wd
doesn't change where the executable is generated (that's the--output
flag), it changes where it is executed.