I am completely new to GoLang, so chances are I messed up my setup.
Here is what I have :
echo $GOPATH
/Users/name/Documents/Developer/Go_Workspace
This one worked.
name$ go get -v golang.org/x/tools/cmd/oracle
It created 2 subfolders inside the Go_Workspace --> src, bin , pkg.
Then when I try :
go get -u golang.org/x/tools/cmd/oracle
package golang.org/x/tools/cmd/oracle: cannot find package "golang.org/x/tools/cmd/oracle" in any of:
/usr/local/go/src/golang.org/x/tools/cmd/oracle (from $GOROOT)
/Users/name/Documents/Developer/Go_Workspace/src/golang.org/x/tools/cmd/oracle (from $GOPATH)
When enable -v
I see :
Fetching https://golang.org/x/tools/cmd/oracle?go-get=1
Parsing meta tags from https://golang.org/x/tools/cmd/oracle?go-get=1 (status code 200)
get "golang.org/x/tools/cmd/oracle": found meta tag main.metaImport{Prefix:"golang.org/x/tools", VCS:"git", RepoRoot:"https://go.googlesource.com/tools"} at https://golang.org/x/tools/cmd/oracle?go-get=1
get "golang.org/x/tools/cmd/oracle": verifying non-authoritative meta tag
Fetching https://golang.org/x/tools?go-get=1
Parsing meta tags from https://golang.org/x/tools?go-get=1 (status code 200)
golang.org/x/tools (download)
package golang.org/x/tools/cmd/oracle: cannot find package "golang.org/x/tools/cmd/oracle" in any of:
/usr/local/go/src/golang.org/x/tools/cmd/oracle (from $GOROOT)
/Users/name/Documents/Developer/Go_Workspace/src/golang.org/x/tools/cmd/oracle (from $GOPATH)
Here is my .bash_profile
1 PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin
2 export GOPATH=$HOME/Documents/Developer/Go_Workspace
3 export PATH=$PATH:/usr/local/go/bin
4 export PATH=$PATH:$GOPATH/bin
Can you help me with this? What did I mess up?
I am running on bash terminal on a MacOS.