I want to use golang, but I'm having trouble running the go command. I installed go1.5.2 darwin/amd64, but when I run the command go version
, I get an error in the terminal zsh: command not found: go
. I added the path export PATH=$PATH:/usr/local/go/bin
to the bash profile, but I still get the error (I restarted the terminal btw). I uninstalled and reinstalled, but no luck. Can anybody help me troubleshoot this? I'm not sure if there was an error in the installation, but it downloaded ok. I may have to download an older version of go if this doesn't workout.
找不到命令go-安装Go后在Mac上
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 邀请回答
-
5条回答 默认 最新
- dongyou8087 2016-01-29 04:19关注
Like bjhaid mentioned in the comments above:
This is happening because you must add your
PATH
to your~/.zshrc
file.in the
~/.zshrc
you should add the line:export PATH=$PATH:/usr/local/go/bin
you should then source you
.zshrc
file:. ~/.zshrc
本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报
悬赏问题
- ¥15 MATLAB怎么通过柱坐标变换画开口是圆形的旋转抛物面?
- ¥15 寻一个支付宝扫码远程授权登录的软件助手app
- ¥15 解riccati方程组
- ¥15 display:none;样式在嵌套结构中的已设置了display样式的元素上不起作用?
- ¥30 用arduino开发esp32控制ps2手柄一直报错
- ¥15 使用rabbitMQ 消息队列作为url源进行多线程爬取时,总有几个url没有处理的问题。
- ¥15 Ubuntu在安装序列比对软件STAR时出现报错如何解决
- ¥50 树莓派安卓APK系统签名
- ¥65 汇编语言除法溢出问题
- ¥15 Visual Studio问题