I'm missing something fundamental. I have set GOROOT to my current directory, which contains my go source files but I can't test a trivial program
treesort_test.go:11:2: package treesort is not in GOROOT (C:\Program Files\Go\src\treesort) It looks like the value of the GOROOT variable is set to a different value inside go itself, and not to the value that the shell sees. (the program is treesort from the Kernigan and Donovan book) // Copyright © 2016 Alan A. A. Donovan & Brian W. Kernighan. // License: https://creativecommons.org/licenses/by-nc-sa/4.0/ // See page 101. Sorry for the long PWD, but I'm trying to keep these trivial programs in github and the path seems to be required. pfarrell@Alien15:~/whome/sandbox/gows/src/github.com/pfarrell51/cmd$ echo $GOROOT /home/pfarrell/whome/sandbox/gows/src/github.com/pfarrell51/cmd pfarrell@Alien15:~/whome/sandbox/gows/src/github.com/pfarrell51/cmd$ go test treesort_test.go # command-line-arguments treesort_test.go:11:2: package treesort is not in GOROOT (C:\Program Files\Go\src\treesort) FAIL command-line-arguments [setup failed] FAIL pfarrell@Alien15:~/whome/sandbox/gows/src/github.com/pfarrell51/cmd$ echo $GOROOT /home/pfarrell/whome/sandbox/gows/src/github.com/pfarrell51/cmd pfarrell@Alien15:~/whome/sandbox/gows/src/github.com/pfarrell51/cmd$ printenv GOROOT /home/pfarrell/whome/sandbox/gows/src/github.com/pfarrell51/cmd This has to be something trivial that I'm doing wrong Thanks -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/75010da9-b72d-4818-80cf-84b622b67f57n%40googlegroups.com.