<p>I use godoc from cli, but often miss autocompletion.</p>
<p>I now created a sollution for this using bash_completion. I have put it out there: <a href="https://gitlab.com/kjell/godoc-ac/" rel="nofollow">https://gitlab.com/kjell/godoc-ac/</a>
in case this could be useful for some of you.</p>
<p>(its tested on debian and ubuntu)</p>
<hr/>**评论:**<br/><br/>arp242: <pre><p>Looks nice.</p>
<p>You shouldn't use GOPATH directly though, for example in <code>find $GOPATH/src/$cur*</code> and a few other commands.</p>
<p>The problem is that GOPATH works like PATH: it's a colon-separated <em>list</em> of pathnames. I have mine set to <code>$HOME/go:$HOME/work</code>, as I would like to keep the various <code>go get ...</code> packages and actual work-related code separate.</p>
<p>It's also a good idea to add quotes around pathnames (<code>find "$GOPATH/src/$cur"*</code>), otherwise stuff will break with spaces and such ;-)</p></pre>kjell_k: <pre><p>Thanks for your reply. I look into it :)</p></pre>icholy: <pre><p>The golang plugin in oh-my-zsh works very well <a href="https://github.com/robbyrussell/oh-my-zsh" rel="nofollow">https://github.com/robbyrussell/oh-my-zsh</a></p></pre>
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889
- 请尽量让自己的回复能够对别人有帮助
- 支持 Markdown 格式, **粗体**、~~删除线~~、
`单行代码`
- 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
- 图片支持拖拽、截图粘贴等方式上传