Skip to content

Instantly share code, notes, and snippets.

@ph5i
Last active February 11, 2025 10:54
Show Gist options
  • Save ph5i/7ef180532fc89cfbc432da2ab64c2d61 to your computer and use it in GitHub Desktop.
Save ph5i/7ef180532fc89cfbc432da2ab64c2d61 to your computer and use it in GitHub Desktop.
go installation that doesn't lead to 1 million path issues
wget https://go.dev/dl/go1.23.6.linux-amd64.tar.gz
rm -rf /usr/local/go && tar -C /usr/local -xzf go1.23.6.linux-amd64.tar.gz
vi ~/.zshrc
export GOPATH=/usr/local/go
export GOBIN=/usr/local/go/bin
export PATH=$PATH:$GOBIN
source ~/.zshrc
# perm issues
rm -rf /usr/local/go && tar -C ~/ -xzf go1.23.6.linux-amd64.tar.gz
export GOPATH=$HOME/go
export GOBIN=$GOPATH/bin
export PATH=$PATH:$GOBIN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment