diff options
author | Robert Griesemer <gri@golang.org> | 2009-11-06 14:00:49 -0800 |
---|---|---|
committer | Robert Griesemer <gri@golang.org> | 2009-11-06 14:00:49 -0800 |
commit | fabe9b0c22ea1ddb4dcf6cd1664795f60a201ba4 (patch) | |
tree | 38d023a13ff1dab4fdf8fbd15e46c73c88cca5a5 /src/cmd/godoc/doc.go | |
parent | 8a1463f2e27164baaf4c230e18fec67cbc898ce0 (diff) | |
download | golang-fabe9b0c22ea1ddb4dcf6cd1664795f60a201ba4.tar.gz |
updated godoc documentation
R=r
http://go/go-review/1026007
Diffstat (limited to 'src/cmd/godoc/doc.go')
-rw-r--r-- | src/cmd/godoc/doc.go | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/src/cmd/godoc/doc.go b/src/cmd/godoc/doc.go index cdf107ab2..a116e321f 100644 --- a/src/cmd/godoc/doc.go +++ b/src/cmd/godoc/doc.go @@ -25,11 +25,13 @@ The flags are: verbose mode -tabwidth=4 width of tabs in units of spaces + -cmdroot="src/cmd" + root command source directory (if unrooted, relative to -goroot) -tmplroot="lib/godoc" - root template directory (if unrooted, relative to --goroot) + root template directory (if unrooted, relative to -goroot) -pkgroot="src/pkg" - root package source directory (if unrooted, relative to --goroot) - -html= + root package source directory (if unrooted, relative to -goroot) + -html print HTML in command-line mode -goroot=$GOROOT Go root directory @@ -42,5 +44,17 @@ The flags are: -sync_minutes=0 sync interval in minutes; sync is disabled if <= 0 +When godoc runs as a web server, it creates a search index from all .go files +under $GOROOT (excluding files starting with .). The index is created at startup +and is automatically updated every time the -sync command terminates with exit +status 0, indicating that files have changed. + +If the sync exit status is 1, godoc assumes that it succeeded without errors +but that no files changed; the index is not updated in this case. + +In all other cases, sync is assumed to have failed and godoc backs off running +sync exponentially (up to 1 day). As soon as sync succeeds again (exit status 0 +or 1), the normal sync rhythm is re-established. + */ package documentation |