internal

package
v0.0.0-...-55358d4 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2024 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const LatestVersion = "latest"

Variables

View Source
var (
	// ErrNotFound indicates that the requested module was not found.
	ErrNotFound = errors.New("not found")

	// ErrInvalidPath indicates that the requested module path is invalid.
	ErrInvalidPath = errors.New("invalid path")

	// ErrInvalidVersion indicates that the requested version is invalid.
	ErrInvalidVersion = errors.New("invalid version")

	// ErrBadModule indicates a problem with a module.
	ErrBadModule = errors.New("bad module")

	// ErrTooLarge indicates that the requested module is too large to fetch.
	ErrTooLarge = errors.New("too large")
)

Functions

This section is empty.

Types

type Module

type Module struct {
	ModulePath    string
	RawModulePath string
	SeriesPath    string
	Version       string
	RawVersion    string
	Reference     string
	CommitTime    time.Time
	LatestVersion string
	Versions      []string
	Deprecated    string
	Updated       time.Time // TODO: remove this
	ZipSize       int64
}

Module contains module information.

type Source

type Source interface {
	Module(modulePath, version string) (*Module, error)
	Files(module *Module) (fs.FS, error)
}

Source represents a source of Go modules.

type SourceList

type SourceList []Source

SourceList fetches modules by trying a list of module sources.

func (SourceList) FindModule

func (list SourceList) FindModule(modulePath, version string) (Source, *Module, error)

FindModule finds the given module, returning the module and the module source which resolved it.

Directories

Path Synopsis
Package autodiscovery implements the [VCS Autodiscovery RFC].
Package autodiscovery implements the [VCS Autodiscovery RFC].
Package database manages the storage of documentation.
Package database manages the storage of documentation.
Package godoc is for rendering Go documentation.
Package godoc is for rendering Go documentation.
codec
Package codec implements the general-purpose part of an encoder for Go values.
Package codec implements the general-purpose part of an encoder for Go values.
Package httputil provides HTTP utility functions.
Package httputil provides HTTP utility functions.
Package proxy provides support for fetching modules from a Go module proxy.
Package proxy provides support for fetching modules from a Go module proxy.
Package render implements rendering of Go code.
Package render implements rendering of Go code.
Package server implements the Go documentation server.
Package server implements the Go documentation server.
Package stdlib supports special handling of the Go standard library.
Package stdlib supports special handling of the Go standard library.

Jump to

Keyboard shortcuts

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