Tool that helps you to retrieve latest Go update from Google
Goup is a little utility that helps you to check and upgrade your local non-container Go version. It bascially does the following step-by-step:
- Run
go versionto determine local Go version andgo envfor$GOPATH. The location ofgois determined by supplied-pparam,$PATHvariable or default installation location (/usr/local/goorC:\Go) - Check https://go.googlesource.com/go/+refs to see if there is a version (tags starts with
go), compare it against local version retrieved in (1). Can include beta, RC and latest major/minor version for comparison with-b,-rcand-u. - If there is a new version available, download it to temporary directory.
- Backup existing Go installtion to temp.
- Extract new Go archive to
$GOROOT. - In case of an error, reverse backup to
$GOROOT.
go get -u github.com/mkishere/goup
go build cmd/goup.go
goup