How do I downgrade Go from 1.10 to 1.9?

22,738

Solution 1

The same way you upgrade. That is, remove the existing version, then install the new version. Although "downgrade" isn't explicitly stated on the official docs, it does explain how to do it.

Solution 2

First remove go from the system

  • sudo snap remove go

Then install particular version of go

  • sudo snap install --classic --channel=1.14/stable go

Solution 3

I don't know if you need to downgrade Go in order to reenable the debugging. I had the same problem on a Mac(10.13) and the problem seems to be XCode.

Here I've found the solution for fixing the debugging problem.

You should delete the current XCode Command Line Tools binary:

sudo rm -rf /Library/Developer/CommandLineTools

and install an older XCode Command Line Tools (for me it's working with 9.2) using one of the following links:

Share:
22,738
Harold Ship
Author by

Harold Ship

I'm a professional programmer. I like to program in Python and Javascript. I also can program in Java, C, SQL, and R. In the past I worked with C++ and Erlang as well. I know some HTML and CSS too.

Updated on October 10, 2020

Comments

  • Harold Ship
    Harold Ship over 3 years

    I have a problem with debugging in Go 1.10 in vscode using delve on Mac. I read here that the workaround is to downgrade to Go 1.9. Since I am new at Go, but have lots of stuff already installed, how do I do this cleanly?

    • Harold Ship
      Harold Ship about 6 years
      Well, I just downloaded 1.9.5 darwin installer from golang.org and it uninstalled 1.10 and now the debugger works!