<p>I love fish but I need to switch into bash to actually use Go because the PATH updates either don't work or are temporary. </p>
<hr/>**评论:**<br/><br/>thesnowmancometh: <pre><p>In <code>~/.config/fish/config.fish</code>, append the line <code>set -x GOPATH "<gopath>"</code> where <code><gopath></code> is the path to your GOPATH.</p></pre>justinisrael: <pre><p>I've never used fish shell, but can you just update your configuration file with GOPATH and PATH?
<a href="https://fishshell.com/docs/current/faq.html#faq-login-cmd" rel="nofollow">https://fishshell.com/docs/current/faq.html#faq-login-cmd</a></p></pre>reddit_is_r_cringe: <pre><p>The way recommended in the FAQ doesn’t seem to work — it only temporarily changes it to work for Go, while commands like ls become broken (but cd works for some reason)</p></pre>KenjiTakahashi: <pre><p>I know it's just a side thing, but <code>cd</code> is (usually) a shell builtin, whereas <code>ls</code> is a separate program. Something probably messes up the "standard" <code>PATH</code>.</p></pre>AndyNemmity: <pre><p>I use fish shell, and it just works. Can you give more detail on your problem?</p></pre>alistercabral: <pre><p>export GOPATH=your_path_here</p></pre>
Can anyone help me configure the GOPATH in fish shell? (and PATH if you know off hand)
blov · · 372 次点击这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889
0 回复
- 请尽量让自己的回复能够对别人有帮助
- 支持 Markdown 格式, **粗体**、~~删除线~~、
`单行代码`
- 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
- 图片支持拖拽、截图粘贴等方式上传