Documentation
¶
Overview ¶
Package deps analyzes and recursively installs Go package dependencies. It is library functionality similar to `go get`.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Context ¶
func (*Context) Download ¶
Downloads (but does not install) the package at the given import path to the first GOPATH tree. Works like `go get -d`.
type Package ¶
type Package struct {
// Note: These fields are part of the go command's public API.
// See list.go. It is okay to add fields, but not to change or
// remove existing ones. Keep in sync with list.go
Foo bar
Dir string `json:",omitempty"` // directory containing package sources
ImportPath string `json:",omitempty"` // import path of package in dir
Name string `json:",omitempty"` // package name
Target string `json:",omitempty"` // install path
Goroot bool `json:",omitempty"` // is this package found in the Go root?
Standard bool `json:",omitempty"` // is this package part of the standard Go library?
Stale bool `json:",omitempty"` // would 'go install' do anything for this package?
Root string `json:",omitempty"` // Go root or Go path dir containing this package
// Dependency information
Imports []string `json:",omitempty"` // import paths used by this package
Deps []string `json:",omitempty"` // all (recursively) imported dependencies
DepsNotFound []string `json:",omitempty"` // all (recursive) deps that were not found
// Error information
Incomplete bool `json:",omitempty"` // was there an error loading this package or dependencies?
Error *PackageError `json:",omitempty"` // error loading this package (not dependencies)
DepsErrors []*PackageError `json:",omitempty"` // errors loading dependencies
}
Relevant fields from Package struct in `go list` (cmd/go/pkg.go).
type PackageError ¶
type PackageError struct {
ImportStack []string // shortest path from package named on command line to this one
Pos string // position of error
Err string // the error itself
}
A PackageError describes an error loading information about a package.
func (*PackageError) Error ¶
func (p *PackageError) Error() string
Click to show internal directories.
Click to hide internal directories.




