最近在自学go语言,刚刚开始就遇到了这个无法debug的问题。
具体vscode和go的安装过程不再演示,有很多现有教程,基本都教到了安装go插件,有一些也写了如何配置debug环境。
但是当这些都配置好后,f5想要debug代码时候,就会报错:
Build Error: go build -o d:\language\project\go\study1\__debug_bin.exe -gcflags all=-N -l .
go: go.mod file not found in current directory or any parent directory; see 'go help modules' (exit status 1)