跑步后…
go run main.go
我得到这个错误
go : The term 'go' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
求助:转到Visual Studio代码(假设已安装)ctrl + shift + p打开命令窗口类型
转到:当前的GOPATH
这应该为您提供一个路径,以创建一个名为GOPATH的系统环境变量,并将该路径添加到该变量中。
确保系统环境变量设置为:
GOPATH设置为C:\ Users [用户名] \ go
GOROOT设置为C:\ go \
IDE是Visual Studio代码。