Rebuilding reinstalling upgrading Go - lmmx/devnotes GitHub Wiki
1.6 ⇢ 1.9
-
firstly get the location of Go (
which go
⇒/usr/local/go/bin/go
) -
as outlined here, remove the existing Go (or if you like, keep it for posterity, or in case you need to roll back)
sudo mv /usr/local/go/ /usr/local/go1.6/
-
download the latest binary from golang.org
-
sudo tar -C /usr/local -xzf Downloads/go1.9.2.linux-amd64.tar.gz
-
to confirm, run
go version
⇒go version go1.9.2 linux/amd64