Steps to install Go on Linux
-
wget https://storage.googleapis.com/golang/go1.7.4.linux-amd64.tar.gz -
tar -C /usr/local/ -xzf go1.7.4.linux-amd64.tar.gz -
#Add variables to /etc/profile
vi /etc/profile- #Go environment variables
export GOROOT=/usr/local/go/binexport GOPATH=$PATH:$GOROOT/binsource /etc/profile
-
Check the current version
go version -
Build Go
/usr/local/go/src./all.bash
NOTICE
- If the previous version (go1.6) is not installed, install the older version before continuing with the newer one.