030*_*030 1 eclipse import go goclipse
根据这篇文章,可以在GoClipse中启用自动导入:
Run Code Online (Sandbox Code Playgroud)1) install goimports: go get code.google.com/p/go.tools/cmd/goimports 2) in eclipse goto: Preferences -> Go -> Go Formatter and set it to be the path of the goimports bin This will fix all imports when you format. If you combine this with #67, then imports will be automatically fixed on save.
问题
当我尝试在Eclipse中搜索Go Formatter时,找不到它。
我的眼睛引起注意的一件事:
我知道goimports网址不再是google.com/p/go.tools/cmd/goimports。
因此,请尝试以下操作:
go get golang.org/x/tools/cmd/goimportsPreferences->Gogofmt为${GOPATH}/bin/goimports(goimports所在的位置)Eclipse并确保goimports在按CTRL+ SHIFT+ 时使用它F。| 归档时间: |
|
| 查看次数: |
853 次 |
| 最近记录: |