How to configure the Go language development environment with notepad++

Source: Internet
Author: User
This is a creation in Article, where the information may have evolved or changed.

How to configure the Go language development environment with notepad++. Original http://www.oschina.net/question/565065_57085

and http://studygolang.com/articles/2371

First, the preparatory work:
1, install the Go language;
2, add the Go/bin directory to the environment variable;
3, installation notepad++;

II, configuration notepad++ support Go language syntax highlighting
1, download notepad++ 's Go Language Support package (http:// Notepad-plus.sourceforge.net/commun/userdefinedlang/go.zip);
2, Copy the contents of the file Userdefinelang_go.xml to the userdefinelang.xml of the notepad++ directory under Application data;
xp:c:\documents and settings\[username]\application Data\Notepad++
vista/win7:c:\users\[username]\appdata\roaming\notepad++
3, Copy the Go.xml file to the Plugins\apis directory under the notepad++ installation directory (for example: D:\Program files\notepad++\plugins\apis);
4, restart notepad++;

Third, configure the Go Language shortcut keys, through the GONPP

notepad++ Install plugin: GONPP menu plugin (p), plugin manager->show ... Select Gonpp,install here need to be able to secure the connection SourceForge.net

Restart after installation and can be compiled and run using the Alt+r shortcut key.

Third, set the Go language compilation run shortcut keys
Here is a demonstration of the following code:
File name: Test1.go

Package Main

Import "FMT"

Func Main () {
Fmt. Println ("Test")
}

principle:
compilation: 8g-o test1.8 Test1.go
link: 8l-o test1.exe test1.8
run: Test1.exe  
compile link run: 8g-o test1.8 test1.go & 8l-o test1.exe test1.8 & Test1.exe

Specific implementation:
1, open the Test1.go file with notepad++;
2. Press F5 to enter the following in the popup dialog box:
cmd/k 8g.exe-o tmp.8 "$ (Full_current_path)" & 8l.exe-o tmp.exe tmp.8 & del tmp.8 & Tmp.exe & PAUSE & ; Del Tmp.exe & EXIT
Save as "Run Go" and set Ctrl+f6 as the shortcut key;
3, according to CTRL+F6 running procedures;

All right, that's it, I hope it helps you.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.