Image

linux

Go

Install Go on Linux

1 min read
Last update: December 4, 2021

Download and install

wget -c https://golang.org/dl/go1.17.3.linux-amd64.tar.gz
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf go1.17.3.linux-amd64.tar.gz
vim ~/.zshrc
~/.zshrc
export PATH=$PATH:/usr/local/go/bin
export GOPATH="$HOME/go"
PATH="$GOPATH/bin:$PATH"
source ~/.zshrc