Go

GoLand

Using multiple go versions while debugging with GoLand

Native

<aside> <img src="/icons/arrow-right_blue.svg" alt="/icons/arrow-right_blue.svg" width="40px" /> Use the default terminal and not the GoLand terminal, because GoLand has its own environment.

</aside>

  1. Uninstall current version: sudo rm -rf /usr/local/go
  2. Download .tar-File from official go website
  3. extract with sudo tar -C /usr/local -xzf /Users/mattiamueggler/Downloads/go1.22.3.darwin-amd64.tar.gz
  4. restart terminal
  5. check env echo $PATH | grep "/usr/local/go/bin"
  6. check go version: go version

All releases - The Go Programming Language

How to update the Go version

Packages

Installation

# update specific package
go get github.com/username/package-name

Updates

# updates all packages
go get -u all 

# update specific package
go get github.com/username/package-name