doc

command
v0.0.0-...-0140545 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 11, 2024 License: BSD-3-Clause Imports: 17 Imported by: 0

Documentation

Overview

Doc (usually run as go doc) accepts zero, one or two arguments.

Zero arguments:

go doc

Show the documentation for the package in the current directory.

One argument:

go doc <pkg>
go doc <sym>[.<method>]
go doc [<pkg>].<sym>[.<method>]

The first item in this list that succeeds is the one whose documentation is printed. If there is a symbol but no package, the package in the current directory is chosen.

Two arguments:

go doc <pkg> <sym>[.<method>]

Show the documentation for the package, symbol, and method. The first argument must be a full package path. This is similar to the command-line usage for the godoc command.

For commands, unless the -cmd flag is present "go doc command" shows only the package-level docs for the package.

For complete documentation, run "go help doc".

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL