mirror of
https://github.com/golang/go
synced 2024-11-20 07:54:39 -07:00
e6ae13d35d
- show documentation in text mode; e.g.: http://localhost:7777/cmd/godoc/?f=text - simplify template by using $ variable R=r, adg CC=golang-dev https://golang.org/cl/4873045
83 lines
1.3 KiB
Plaintext
83 lines
1.3 KiB
Plaintext
{{with .PAst}}{{node . $.FSet}}{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .PDoc}}{{if $.IsPkg}}PACKAGE
|
|
|
|
package {{.PackageName}}
|
|
import "{{.ImportPath}}"
|
|
|
|
{{else}}COMMAND DOCUMENTATION
|
|
|
|
{{end}}{{.Doc}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Consts}}
|
|
CONSTANTS
|
|
|
|
{{range .}}{{node .Decl $.FSet}}
|
|
{{.Doc}}{{end}}
|
|
{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Vars}}
|
|
VARIABLES
|
|
|
|
{{range .}}{{node .Decl $.FSet}}
|
|
{{.Doc}}{{end}}
|
|
{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Funcs}}
|
|
FUNCTIONS
|
|
|
|
{{range .}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{end}}{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Types}}
|
|
TYPES
|
|
|
|
{{range .}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{range .Consts}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{end}}{{range .Vars}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{end}}{{range .Factories}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{end}}{{range .Methods}}{{node .Decl $.FSet}}
|
|
{{.Doc}}
|
|
{{end}}{{end}}{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Bugs}}
|
|
BUGS
|
|
|
|
{{range .}}{{.}}
|
|
{{end}}{{end}}{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .PList}}
|
|
OTHER PACKAGES
|
|
|
|
{{range .}}
|
|
{{.}}{{end}}
|
|
{{end}}{{/*
|
|
|
|
---------------------------------------
|
|
|
|
*/}}{{with .Dirs}}
|
|
SUBDIRECTORIES
|
|
|
|
{{range .List}}
|
|
{{.Name}}{{end}}
|
|
{{end}}
|