Skip to content

Instantly share code, notes, and snippets.

@ionutvilie
Last active April 1, 2017 09:30
Show Gist options
  • Save ionutvilie/c329d115d4e0cb563fca6e4e65468b02 to your computer and use it in GitHub Desktop.
Save ionutvilie/c329d115d4e0cb563fca6e4e65468b02 to your computer and use it in GitHub Desktop.
windows linux subsytem ubuntu install golang
# i did not checket on pure ubuntu but it should work
#Download and unpack golang go
curl https://storage.googleapis.com/golang/go1.8.linux-amd64.tar.gz -o go1.8.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.8.linux-amd64.tar.gz
#update and set alternatives from windows ubuntu subsystem
#update-alternatives: --install needs <link> <name> <path> <priority>
sudo update-alternatives --install "/usr/bin/go" "go" "/usr/local/go/bin/go" 1
sudo update-alternatives --set "go" "/usr/local/go/bin/go"
#check if all good
update-alternatives --list go
update-alternatives --query go
go version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment