Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Offline tour doesn't work #31402

Closed
kstenerud opened this issue Apr 11, 2019 · 2 comments
Closed

Offline tour doesn't work #31402

kstenerud opened this issue Apr 11, 2019 · 2 comments

Comments

@kstenerud
Copy link

kstenerud commented Apr 11, 2019

What version of Go are you using (go version)?

$ go version
go version go1.12.2 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/karl/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/karl/go"
GOPROXY=""
GORACE=""
GOROOT="/snap/go/3540"
GOTMPDIR=""
GOTOOLDIR="/snap/go/3540/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build552374246=/tmp/go-build -gno-record-gcc-switches"

What did you do?

I followed the instructions at https://tour.golang.org/welcome/3

go get golang.org/x/tour
tour

What did you expect to see?

"The tour program will open a web browser displaying your local version of the tour."

What did you see instead?

karl@tp-dev:~/Projects/tmp/go$ go get golang.org/x/tour
karl@tp-dev:~/Projects/tmp/go$ tour

Command 'tour' not found, did you mean:

  command 'tor' from deb tor

Try: sudo apt install <deb name>
@agnivade
Copy link
Contributor

Hi @kstenerud - welcome to Go. Please go through https://golang.org/doc/code.html#GOPATH to get an idea of how Go tools are installed. You have to set the $GOPATH/bin folder in your $PATH variable for it to know where the binaries are installed.

@kstenerud
Copy link
Author

That's pretty confusing for a newcomer. I would never have thought in a million years that I'd need information from an obscure section of a random URL in order to run a command on page 3 of the tutorial.

Even the documents at https://golang.org/doc/code.html#GOPATH are unclear:

"For convenience, add the workspace's bin subdirectory to your PATH:"

"For convenience" doesn't imply that instructions as given simply won't work unless I do it, nor does the tutorial mention that you need to do this in order to run the commands.

@golang golang locked and limited conversation to collaborators Apr 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants