This is a creation in Article, where the information may have evolved or changed.
Built a development environment to develop the go language, to share the first Hello World written in the go language, we hope to help you.
1. To write the Go language first download the Go Language Development kit
Official Download Address: https://code.google.com/p/go/downloads/list
I am using the Win7 64-bit operating system, as follows:
2. Extract the downloaded files to the folder you want to unzip, unzip to the root directory of the C drive, the file is named go, and then set the environment variables:
Environment variables, advanced system settings, properties, computer
Add C:\go\bin to the path in the system variable, as shown in:
Test environment variable is set successfully:
Run the go command in CMD and the following interface explains the setting environment variable success:
3. Install the Goclips plugin on the eclips:
(1). Open eclips->help->install New software ... As shown, enter the plugin URL:http://goclipse.googlecode.com/svn/trunk/goclipse-update-site/as shown
Then the next installation is ready, and after the install succeeds in Windows->preferences open Preferences as shown, and configure the information into the following:
4. Configure the debugger (optional)
need to install MinGW, download address:http://sourceforge.net/projects/mingw/files/MinGW/, loaded as follows:
After installation, open the configuration options box for the debugger via the menu item "window"-"Preferences"-"Go"-"Debugger".
Configure the GDB path to: MinGW the Gdb.exe file in the installation directory.
5. Write the first Go language program:
File--New->other->goproject Create a Go Project
Add go file under the SRC folder in the new project, and edit the first go document "Hello World";
Run out as shown in the following:
To this go language environment to build complete.