You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.
Debug: Start without Debugging is the command to use to simply run the current file rather than debugging.
This works just fine just fine in the below cases:
No launch.json file or it is empty
The currently selected debug configuration in launch.json has the program attribute pointing to a file.
This falls back to debugging when the program attribute in the currently selected debug configuration points to a directory. This is because go run needs a file.
In such cases, we should use the file open in the currently active editor instead of falling back to debugging the package.
Update resolveDebugConfiguration in goDebugConfiguration.ts file to return a new property called currentFile. This should have the path to file open in the active editor.
Debug: Start without Debugging
is the command to use to simply run the current file rather than debugging.This works just fine just fine in the below cases:
program
attribute pointing to a file.This falls back to debugging when the
program
attribute in the currently selected debug configuration points to a directory. This is becausego run
needs a file.In such cases, we should use the file open in the currently active editor instead of falling back to debugging the package.
PRs are most welcome to fix this.
Code Pointers:
resolveDebugConfiguration
ingoDebugConfiguration.ts
file to return a new property calledcurrentFile
. This should have the path to file open in the active editor.go run
call at https://github.com/Microsoft/vscode-go/blob/master/src/debugAdapter/goDebug.ts#L317 to use the value from thecurrentFile
property if theprogram
property does not point to a file itselfThe text was updated successfully, but these errors were encountered: