3

I am trying to install Go version 1.16 using a snap package, but not able to. Instead I am getting newer versions.

How can I install version 1.16 regardless of what version is currently available?

matigo
  • 20,403
  • 7
  • 43
  • 70
Vimal
  • 41
  • 1
  • 4

1 Answers1

10
  1. you can run snap info go, which gives you a list of go versions.

    sudo snap info go
    
  2. Then you can install your preferred version with --channel like this.

    sudo snap install go --channel=1.16/stable --classic
    

This will also work for upgrade / downgrade to specific version after installation. For example you want to downgrade from 1.17 go version to 1.16

sudo snap refresh go --channel=1.16/stable --classic
guettli
  • 2,932
  • 12
  • 67
  • 115
Billi
  • 216
  • 2
  • 3