Dive into my collection of in-depth articles, research papers, and long-form content. Each publication represents hours of research, thought, and careful crafting.
Golang is self-contained, it has no external dependencies. So upgrading a full Ubuntu distribution seems extreme, when the need is just being able to compile with "go 1.12" when you have "go 1.10" already installed on your system.
Go to https://launchpad.net/ubuntu/+source/golang-1.12 and search for the desired version. At the time of writing, the last stable is "1.12-1ubuntu1". Then locate the desired build (amd64, arm64, etc...) and download all the *.deb built files and put them in a new directory. In my case it's those :
Then open a console and "cd" the directory then execute the command: "sudo dpkg -i *.deb". If external dependencies were needed, a "sudo apt install -f" would fix them.
"which go" will tell you what program is called when you type "go" in a console. In my case it's "/usr/bin/go".
If it's a link then "ll /usr/bin/go" will tell you where the link resolves, in my case it's "/usr/bin/go -> ../lib/go-1.10/bin/go*". Now to complete the upgrade, you only need to overwrite those 3 links: