Autocomplete for godoc - (bash) commandline.

polaris · · 435 次点击    
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
<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&#39;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&#39;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&#39;s also a good idea to add quotes around pathnames (<code>find &#34;$GOPATH/src/$cur&#34;*</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

435 次点击  
加入收藏 微博
暂无回复
添加一条新回复 (您需要 登录 后才能回复 没有账号 ?)
  • 请尽量让自己的回复能够对别人有帮助
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`
  • 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
  • 图片支持拖拽、截图粘贴等方式上传