I am happy with where this is going, just want to try to clean up the
File src/cmd/godoc/godoc.go (right):
src/cmd/godoc/godoc.go:1052: // then it is not usable as command docs.
This is not true. A Go command can be in package main and have docs in
package main. 'Package documentation' is a hack for commands written in
C. I don't know if that affects the surrounding code, but the comment
should be more precise.
File src/cmd/godoc/main.go (right):
src/cmd/godoc/main.go:384: // If command docs are present, choose them
above all else.
This is different from the way it used to work.
It used to be that package wins unless you say cmd/.
src/cmd/godoc/main.go:406: fmt.Printf("use 'godoc %s%s' for
documentation on the %s command \n\n", cmdPrefix, relpath, relpath)
How does this work anymore without forceCmd?
I'm pretty lost at this point in the code. Can you make this clearer?
Grokbase › Groups › Go › golang-dev › January 2013