下载版本选择
下载完成之后 无需配置环境变量
windows
打开cmd 执行
go version
查看go 安装版本检查是否安装成功
Mac/Linux
打开Terminal 执行
go version
查看go 安装版本检查是否安装成功
特别注意:
1、windows安装go建议不要安装到C盘可能会有权限问题,后期不好处理。建议安装到除C盘以外的盘。
2、安装完成后、执行go env 查看GOPATH 目录
GOPATH : Go 的工作空间,就是我们的开发和依赖包的目录(例如:我的是 D:gopath) ,此目录需要手动配置到系统环境变量(使用IDEA开发的可以忽略)
GOPATH 工作空间是一个目录层次结构,其根目录包含三个子目录:src、pkg、bin。
1、windows下使用go get命令下载出现
exec: "gcc": executable file not found in %PATH%
解决方式
参考文章:https://www.cnblogs.com/zsy/p/5958170.html
软件下载地址:https://sourceforge.net/projects/mingw-w64/
安装完成软件后记得配置环境变量。
即可。
2、错误 could not launch process: EOF 解决
解决:
1、更新dlv,go get -u github.com/derekparker/delve/cmd/dlv
2、修改Goland的配置,Help->Edit Custom Properties中增加新版dlv的路径配置:dlv.path=/path/go/bin/dlv
注:如替换后无效 请下载GoLang idea使用,可能是go插件版本不匹配
其他1. IDE 的下载安装这里就不说,大家直接去这个地址下载就行。
Goland:https://www.jetbrains.com/go/download/#section=windows
或者直接使用IDEA、安装go插件也可以。不用去多下载一个开发工具。
附图:
N757JE0KCT-eyJsaWNlbnNlSWQiOiJONzU3SkUwS0NUIiwibGljZW5zZWVOYW1lIjoid3UgYW5qdW4iLCJhc3NpZ25lZU5hbWUiOiIiLCJhc3NpZ25lZUVtYWlsIjoiIiwibGljZW5zZVJlc3RyaWN0aW9uIjoiRm9yIGVkdWNhdGlvbmFsIHVzZSBvbmx5IiwiY2hlY2tDb25jdXJyZW50VXNlIjpmYWxzZSwicHJvZHVjdHMiOlt7ImNvZGUiOiJJSSIsInBhaWRVcFRvIjoiMjAyMC0wMS0wNyJ9LHsiY29kZSI6IkFDIiwicGFpZFVwVG8iOiIyMDIwLTAxLTA3In0seyJjb2RlIjoiRFBOIiwicGFpZFVwVG8iOiIyMDIw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