Goeclipse Plugin Guide
http://goclipse.github.io/
Overview
Goclipse for an Eclipse IDE's go programming language.
Characteristics
Installation
User Guide
GitHub (latest release) (Report issue)
Goclipse user Group-Discussion and help, Goclipse
Installation requires Java VM version 8 or later. Eclipse 4.6 (Neon) or later. CDT 9.0 or later (this'll is installed or updated automatically as part of the steps below). Start Installation Offline Installation
Because GFC is closed, we need to go to Https://github.com/GoClipse/goclipse.github.io/archive/master.zip to download the Goclipse installation package and unpack it. Then turn on eclipse (make sure you already have the CDT), help-> Install New Software ..., and then select the Add button, enter the unpacked release directory, select Goclipse, and then always install next to succeed. You will need to restart eclipse after the installation is complete.
Online Installation
Directly on the operation diagram
Open: Help>install New Software
Because I have already installed, so this step is not shown.
Install complete, restart Eclipse configuration
Open: Window>preferences
Then press the key and apply to save the changes
The next task, basically, is to complete these three configurations
"Note" the compilation of the full version of the three plug-ins have been uploaded to Csdn, you can download directly use (http://download.csdn.net/download/a314368439/10133928)
There are two ways to complete this configuration, you can choose which you have already downloaded and compile the Go program, or click Download ... button to perform the download can gocode configuration one: Run >cmd>dos command,
#获取gocode go
get-u github.com/nsf/gocode
#编译gocode go build
github.com/nsf/gocode
1 2 3 4
After compiling successfully, click Browse Manually ... button, select the%gopath%/bin/gocode.exe godef configuration mode two: Click Download ... Button Execution
Why don't I configure these three items in order because Gurn has a problem gurn configuration
We use the way to configure, see Go Tools Log
You can see that the Gurn access path is: Golang.org/x/tools/cmd/guru
Even if the way two not, then take a look at the way
This path is inaccessible.
Then we will use the browser to visit this link to see.
Finally use the address on the GitHub to get gurn on it.
Https://github.com/golang/tools/tree/master/cmd/guru
Can be implemented by way of.
Attention:
Build, it's go build Github.com/golang/tools/cmd/guru, not
Go build Github.com/golang/tools/tree/master/cmd/guru.
To compile according to the actual directory
Execution, error
Can ' t load package:package github.com/golang/tools/cmd/guru:code in directory E:\0Develop\Android\Battery historian\ Go\work\src\github.com\golang\tools\cmd\guru expects import "Golang.org/x/tools/cmd/guru"
1
Apparently, the. Go file import a lot of golang.org/x as a prefix of the path
Workaround:
Shift the Github.com/golang/->tools from the GitHub down to the golang.org/x/.
To execute the compile command again:
Go Build Golang.org/x/tools/cmd/guru
1
Final Result:
Test Goeclipse
Open: File>new>other ..., find
Create a Go Project
Then create a hello.go
This is not allowed to run at this time.
Solving method
Open: Window>preferences
You have to hook this up.
OK, let's run it again.
Left >run as>go Application
Run failed
We found that the error has been made.
Workaround:
You cannot put the. go file directly under src/.
Since then, the Goeclipse plug-in installation is complete, the following installation of the debug plug-in, if directly in eclipse to configure GDB for the Liteide tool installation directory under the bin/ Gdb64.exe can not run directly, you need to install MinGW First, download the address as follows: https://sourceforge.net/projects/mingw-w64/files/mingw-w64/, download the installation directly, Then configure the Gdb64.exe, if the direct configuration MinGW installation directory Bin/gdb.exe debug error, the reason is unknown.
Save well to debug debugging