-
Notifications
You must be signed in to change notification settings - Fork 0
Go Installation
Narongsak Mala edited this page Mar 24, 2020
·
1 revision
If you are ready, update the Ubuntu packages on your machine. This ensures that you have the latest security patches and fixes, as well as updated repos for your new packages.
sudo apt-get update
Download latest Go version
see more, https://golang.org/dl/
cd /tmp/
curl -O https://storage.googleapis.com/golang/go1.14.1.linux-amd64.tar.gz
tar -xvf go1.14.1.linux-amd64.tar.gz
sudo mv go /usr/local
Set Go's home path by using $HOME/go
sudo nano ~/.profile
export GOPATH=$HOME/go
export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin
Active profile
source ~/.profile
Show version
go version