"Go Language" "2" Sublime configuration Go Development environment

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

First, download sublime Text3

Readers can download HTTP://WWW.SUBLIMETEXT.COM/3 on official website

"Remarks":

Since I am using an operating system that is WIN8 64 bit, select the Windows * + bit link to download


Second, registered sublime TEXT3

1, installed after the open sublime text will find that the software is not registered, in fact, not registered relationship is not very small, just in the back when using the box will affect the ease of use

2. Open Sublime Text and select "Help > Enter License"

3, enter the registration code ( Note the Begin and end row also copied past ), click Use License

-----BEGIN LICENSE-----

K-20

Single User License

ea7e-940129

3A099EC1 c0b5c7c5 33EBF0CF be82fe3b

eac2164a 4f8ec954 4e87f1e5 7e4e85d6

C5605de6 dab003b4 d60ca4d0 77cb1533

3c47f579 fb3e8476 Eb3aa9a7 68C43CD9

8c60b563 80fe367d 8cad14b3 54fb7a9f

4123FFC4 d63312ba 141af702 f6bba254

B094B9C0 faa4b04c 06CC9AFC FD412671

82e3aee0 0f0faaa7 8fa773c9 383a9e18

------END LICENSE------


"Remark": the registration code is valid for the 3065 version and I have not tried other versions


Third, install the package control plug-in for sublime text

There are a lot of articles on the Internet are installed through the input command, but in some networks this command will fail to perform, so here to manually install

1, from https://sublime.wbond.net/Package%20Control.sublime-package Download plugin (note: The plugin is also available in my upload center)

2. Open Sublime text and select "Preferences > Browse Packages"

3, on the basis of the open path upward level, find and enter the "Installed Packages" directory

4, the 1th step download "Package Control.sublime-package" copy to installed packages below

5. Restart Sublime Text, if you find the Package Control submenu item under the Preferences menu to indicate that the installation was successful


Iv. installation of Gosublime plug-in

It is necessary to install the package control in the third step to allow sublime text to automatically install the Gosublime plugin or other plug-in

1. Open Sublime Text, then press CTRL + Shift + P shortcut to open a search window

2. After entering PCI in the input box, select the first item "Package Control:install package"

3, such as sublime text automatic search, we enter "Gosublime"

4, enter the auto-install Gosublime plug-in, but wait a moment, you will be prompted to set Gopath system variables

Gopath=%goroot%;%gobin%;%goroot%\src

"Note": Gopath can be a directory for go to find the package directory, when using the import package name, if not found in the Goroot, will turn to Gopath to find


V. Test the success of Gosublime plug-in installation

1. Open Sublime Text to enter the following content

Package Main

Import "FMT"

Func Main () {

Fmt. Println ("Hello My GO")

}

2, select "File > Save with Encoding > UTF-8", as to why here choose UTF-8 in the back to explain

3, Save as Hello.go, this time the file should be automatically formatted

4. Press "Ctrl + B" to enter "Go run Hello.go" in the box that opens below

5, enter, the program will run and output "Hello my GO"


Vi. concluding remarks

1, install the Gosublime plug-in in the fourth step, if for some reason the automatic installation is unsuccessful, can be installed manually. The installation method is to open sublime text after selecting "Preferences > Browse Packages", then my upload center The Gosublime.zip compressed package in this article is downloaded and extracted to the current directory


2, if the Linux operating system installed sublime Text3 will appear unable to input Chinese, the corresponding solution can be searched on the internet

This article is from the "Green Guest" blog, please be sure to keep this source http://qingkechina.blog.51cto.com/5552198/1614162

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.