I'm trying follow these instructions to install Drive but I can't get Go
to work properly.
I keep getting the error:
go tool: no such tool "6g"
When I try to use go get [url]
. I also get this error when trying to run a hello world script (to check that Go had installed correctly).
I've tried installing the individual programs recommended in this post (golang-go.tools gccgo-go) regarding fixing this error but the problem persists.
How can I get the 6g
tool?
Here are the results of go env
:
GOARCH="amd64"
GOBIN=""
GOCHAR="6"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/user/go"
GORACE=""
GOROOT="/usr/share/go"
GOTOOLDIR="/usr/share/go/pkg/tool/linux_amd64"
TERM="dumb"
CC="gcc"
GOGCCFLAGS="-g -O2 -fPIC -m64 -pthread"
CXX="g++"
CGO_ENABLED="1"
sudo apt-get install golang
.sudo apt-get install golang
but it returned 0 to upgrade, newly install, 62 not to upgrade and I'm still unable to usego get
andgo run
. Do I need to force apt-get to overwrite my current version of Go?