英文:
How to enable autocomplete in GoClipse?
问题
我已经按照安装GoClipse的说明进行了操作。
无论是我自己编写的本地包,还是内置的包,或者GAE的包(我已经按照维基上的说明将Go源代码下载到SDK文件夹中),都没有出现任何自动补全的情况。
有没有任何设置可以检查以确保它已正确设置?当前版本中是否应该支持自动补全?
英文:
The instructions how to install GoClipse have been followed.
I'm not getting any autocomplete stuff happening at all, either for local packages that I write, for built in stuff, or for GAE stuff (I have downloaded Go src to the SDK folder as the wiki states).
Are there any settings that I can check to ensure it is set up correctly? Is autocomplete supposed to work in the current version?
答案1
得分: 5
正如你提供的链接中的GoClipse与AppEngine文章所说:
> 我们假设读者在他们的Eclipse环境中有一个可用的GoClipse副本。
所以这不是你想要参考的文章。相反,请查看GoClipse。
自动完成在Eclipse中被称为内容辅助。GoClipse的功能说明如下:
> 现在通过Windows、OS X 64位和Linux 64位的Gocode提供内容辅助。
Gocode是一个自动完成的守护进程。所以除了你的eclipse + GoClipse之外,你还需要安装和运行它。
英文:
As the GoClipse with AppEngine article you linked to says:
> We assume the reader has a working copy of GoClipse running in their Eclipse environment.
so that’s not the article you want to refer to. Instead, check for GoClipse.
The auto completion is named content assist in eclipse. The GoClipse features state:
> Now delivered with content assist via Gocode for Windows, OS X 64bit, and Linux 64bit.
Gocode is an auto-completion daemon. So you will also have to install and run that one besides your eclipse + GoClipse.
答案2
得分: 2
当前版本的Goclipse在Linux平台上存在一个bug。它目前提供了一个预编译版本的gocode,适用于Windows、64位OS X和64位Linux。我只能在有限的资源下进行本地测试,所以我非常依赖用户在以下网址上报告他们发现的问题:
http://code.google.com/p/goclipse/issues/list
如果您遇到问题,我建议您下载并安装gocode到您的$GOROOT/bin目录中,看看是否有所帮助。否则,修复将在未来几天的下一个版本中发布。
另外,对于给您带来的任何麻烦,我表示抱歉,并感谢您尝试使用Goclipse。
英文:
There is a bug in the current version of Goclipse for the Linux platform. It currently delivers a prebuilt version of gocode for Windows, 64 bit OS X, and 64 bit Linux. I have only been able to test it locally with limited resources, so I really depend on users to report the problems they find at:
http://code.google.com/p/goclipse/issues/list
If you are having problems, I urge you to download and install gocode into your $GOROOT/bin directory and see if that helps. Otherwise, the fix will come in the next release in a few days.
Also, sorry for causing you any trouble and thank you for trying Goclipse.
答案3
得分: 1
如果您在Linux上没有使用gocode的上游版本(而是使用Eclipse附带的版本),那么您将无法使用CRTL+F11构建应用程序,尽管只需点击运行->运行即可正常工作。
因此,我强烈建议您在Linux上更新您的gocode,方法很简单:
$ sudo GOPATH=/opt/go/ go get -u github.com/nsf/gocode
英文:
If you are not using a gocode upstream (but the one shipped with Eclipse) on Linux you are also no be able to build your application with CRTL+F11, although just clicking in Run->Run is going to work.
So, I strongly recommend to update your gocode on Linux, as simple as:
$ sudo GOPATH=/opt/go/ go get -u github.com/nsf/gocode
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论