Last active
April 12, 2016 14:10
-
-
Save jmcarbo/5ce3dc616578775d1bce to your computer and use it in GitHub Desktop.
Install golang
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get update -y && sudo apt-get install -y -q curl build-essential ca-certificates git mercurial bzr | |
sudo mkdir -p /goroot && sudo chown -R `whoami` /goroot && curl https://storage.googleapis.com/golang/go1.4.1.linux-amd64.tar.gz | tar xvzf - -C /goroot --strip-components=1 | |
sudo mkdir -p /gopath && sudo chown -R `whoami` /gopath | |
export GOROOT=/goroot | |
export GOPATH=/gopath | |
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin | |
echo "export GOROOT=/goroot" >> ~/.profile | |
echo "export GOPATH=/gopath" >> ~/.profile | |
echo "export PATH=$PATH:$GOROOT/bin:$GOPATH/bin" >> ~/.profile |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment