Install go language under Ubuntu, Sublime+gocode build; Go uninstall and environment variables with personal. BASHRC;2 Vacancy 3 Net

Source: Internet
Author: User
Tags install go mercurial gocode

36891949

Today, the first day of the seven, very happy, colleagues are very good, shell people are very well

The first day of my task is very easy, a variety of installation configuration, to tell the truth Linux qq really dish, go language installation is very tangled, fortunately, previously installed under the CentOS, this will often connect foreign network east, the network always let me no language

It feels like a fragrance I keep wondering

OK to start the installation

1. Install the GCC tool because Golang some features are written using C

sudo apt-get install Bison gawk gcc Libc6-dev make

2. Install mercurial (if you can ignore this step with the installation package)

Since the go source code is managed through mercurial, it is necessary to install mercurial to achieve the go source, one time to execute the command:

sudo apt-get install python-setuptoolssudo apt-get install pythone-devsudo apt-get install Build-essentialsudo apt-get in Stall Mercurial
Get Code
[Plain]View Plaincopy
    1. $ HG Clone-r Release Https://go.googlecode.com/hg/go
If you use the installation package to directly decompress http://download.csdn.net/detail/u010026901/7592581

Cd/usr/local

TAR-ZXVF go1.1.2.linux-386.tar.gz (move the installation package to this directory first)

3. Installation

$ cd go/src,$./all.bash

Run the bash script and get your operating system and CPU information if it works, automatically compile the installation

4. Configure ~/.BASHRC (personal user environment) or/etc/profile (Global environment)

Note the last two lines, address Goroot address is based on the actual situation

5. Using go version to view, there is a version of the result is right

Go Uninstall

This time, my go installation used both the installation version and the compact version, and there was a conflict in the make Go project.

Now uninstall the installation version of man apt-get find uninstall command

Uninstall Apt-get purge Go unsuccessful

Use Apt-get purge Golang prompt to delete multiple subdirectories

Then use Apt-get purge golang-go

Install go language under Ubuntu, Sublime+gocode build; Go uninstall and environment variables with personal. BASHRC;2 Vacancy 3 Net

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.