https://github.com/chadmayfield/upgrade-go
Upgrading go in 40 lines of bash
https://github.com/chadmayfield/upgrade-go
bash go golang upgrade
Last synced: 9 months ago
JSON representation
Upgrading go in 40 lines of bash
- Host: GitHub
- URL: https://github.com/chadmayfield/upgrade-go
- Owner: chadmayfield
- License: gpl-3.0
- Created: 2019-08-29T03:18:48.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-10-01T00:31:47.000Z (over 1 year ago)
- Last Synced: 2024-11-29T08:39:31.041Z (over 1 year ago)
- Topics: bash, go, golang, upgrade
- Language: Shell
- Homepage: https://chadmayfield.com/2019/08/29/upgrading-go-in-40-lines-of-bash/
- Size: 209 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# upgrade-go
Upgrading [go](https://golang.org) in 40 lines of bash. [Blog post here](https://chadmayfield.com/2019/08/29/upgrading-go-in-40-lines-of-bash/).
### Requirements
* Linux system with [golang](https://golang.org/dl/) installed (usually to `/usr/local/go`)
* A user with `sudo` privileges
* Internet access
* [curl](https://curl.haxx.se)
* tar
* gzip
### Sample Output
```
chad@dev-vm:~$ ./upgrade_go_linux.sh
This will upgrade go... are you sure? (Y/N) y
Found: https://dl.google.com/go/go1.12.9.linux-amd64.tar.gz
Downloading now...
Downloaded 127961523 bytes in 4.606516s
Uncompressing: go1.12.9.linux-amd64.tar.gz
Updated to go version go1.12.9 linux/amd64!
```