joefitzgerald / go-get

An Atom Package For Managing Go Libraries And Executables
Other
5 stars 0 forks source link

go: cannot find GOROOT directory: /tmp/appengine/go_appengine/goroot #8

Open karalabe opened 8 years ago

karalabe commented 8 years ago

When I start up atom, it prompts

The tester-go package uses the cover tool, but it cannot be found.
Would you like to run go get -u golang.org/x/tools/cmd/cover?

even though cover is installed. If I press Run Go Get, it fails with

Error Getting Package
go: cannot find GOROOT directory: /tmp/appengine/go_appengine/goroot
jaredgisin commented 8 years ago

Did you find a solution to this? I have the same issue.

karalabe commented 8 years ago

Nope

jaredgisin commented 8 years ago

The path I see it failing on is this:

/private/var/folders/00/0v42r000h01000cxqpysvccm003chb/T/appengine/go_appengine/goroot

onlyafly commented 8 years ago

I have the same issue:

go: cannot find GOROOT directory: /private/var/folders/zj/06c51mbs71z4r22r59jzffjm003chb/T/appengine/go_appengine/goroot

onlyafly commented 8 years ago

I fixed this by setting my GOROOT manually in my ~/.profile: export GOROOT=/usr/local/go

migueleliasweb commented 8 years ago

I got a similar issue here.

Got both env vars set $GOROOT and $GOPATH and still I can't "go get" any package.

But I can $ go get -u github.com/nsf/gocode on my terminal... :disappointed:

iballbar commented 8 years ago

I have the same issue:

go: cannot find GOROOT directory:

How to fix this?

komagata commented 8 years ago

I have same issue.

flatspyder commented 7 years ago

I have the same issue and think this might be related to having the Golang version of AppEngine installed via Homebrew in addition to the Go binary release from golang.org. The goapp binary is in /usr/local/bin but the Go binary is under /usr/local/go/bin/

My shell GOPATH is to a directory under my home filer and this doesn't seem to get picked up by the go-plus plugin. I've been looking around in locator.js which shows it searches for both the go binary and goapp and might be where the problem lies but haven't managed to follow the logic so far.

tbillington commented 7 years ago

Also getting this. No problems from command line, also started atom through the command line with all my env set up ¯\_(ツ)_/¯

InfinityCoders-com commented 6 years ago

To resolve this: The error shows the path it is looking for files like
go: cannot find GOROOT directory: /home/infinity/go1.X

simply create directory at your home
cd $HOME mkdir go1.X and extract all the files from tar.gz into this folder as this is the GOROOT dir go will look for, Hence it will run smoothly.