This is a creation in Article, where the information may have evolved or changed.
1. Install the Windows version of Go,Golang China has various versions of the domestic mirror, download quickly, this site is not bad, can be used as a learning go resources.
Download Go1.7.windows-amd64.msi and then click Next
When the installation is complete, the GO environment variable is added by default to the system environment variable
2. Configure Environment Variables
(1). New variable name: GOBIN variable value: C:\go\bin
(2). New variable name: Gopath variable value: D:\gopath
(3). New variable name: Goroot variable value: C:\go
Create a directory under Gopath src bin pkg
3. Sublime inside use CTRL shift p, command install to enter module installation mode, need to be installed go Sublime
4. Install Gocode: First make sure that the Windows command line version of Go and Msysgit is installed, and then command:
Go get-u github.com/nsf/gocode
Go install github.com/nsf/gocode
5. Modify the Gosublime configuration: Under the Preferences menu, locate the package Settings, find the Gosublime, and then find Settings-default. Re-open the file, add the following configuration, and save:
6. Note A small problem:
Install Gocode that step, go get-u github.com/nsf/gocode These two commands in console input does not respond, under the CMD line
7. Run the Go file
After installing Gosublime, in the menu bar Tools-"Build system, select Gosublime and then Ctrl +b to run the file