This is a creation in Article, where the information may have evolved or changed.
intelliJJava is the development of a weapon, a very useful IDE, Android Studio is based on intelliJ the change, choose to use intelliJ as Golang the IDE, is very convenient.
Download IntelliJ
First to download http://www.jetbrains.com/idea/
intelliJDivided into Community Edition and Professional version, the recommended use of Professional version, if you do not want to pay, you can also consider the first implementation of the community version is free, the impact on doing Golang or Java development is very small, but use the community version of the intelliJ want to develop html , css and JavaScript It's not that convenient.
Installing the Golang Plugin
GolangPlugin is an open source project, project address: Https://github.com/go-lang-plugin-org/go-lang-idea-plugin
In intelliJ the Plugins can find Golang the plug-in, direct download can. But most of the time because everyone knows why, not sure to be able to search, or to be able to search and not necessarily be able to download, encountered this situation can go to the official web download corresponding jar包 manual installation.
Plugin Address: https://plugins.jetbrains.com/plugin/5047
Download the latest version of the Golang plugin.
Select install plugin form disk Install, you can see the plugin after the installation is complete Golang :
Go Plugin
Configure the Go SDK
In the case of settings GOPATH , the intelliJ Go language directory is automatically found and can be configured if it is not found.
perferencesLanguages&Frameworks Go Go Libraries You can see GOPATH the configuration:
Go Libraries
You can see directly using the system GOPATH , or you can + select GOPATH a location in.
Test
To create a new project, select the Go language:
Go language
To create main.go a new file, enter the code:
package main import "fmt" func main(){ fmt.Println("hello go") }
Direct operation, output result:
hello go