Documentation
¶
Index ¶
- Constants
- Variables
- type CopyAction
- type Entry
- type ExtractAction
- type Git
- func (a *Git) FetchArchive(ctx context.Context, name, version string, platform fetcher.Platform) (io.ReadCloser, int64, error)
- func (a *Git) FetchSource(ctx context.Context, name, version string) (io.ReadCloser, int64, error)
- func (a *Git) Info(ctx context.Context, pkgName string) (*Package, error)
- func (a *Git) List(ctx context.Context) ([]string, error)
- func (a *Git) ListVersions(ctx context.Context, pkgName string) ([]string, error)
- func (a *Git) Update(ctx context.Context) error
- type LocalDir
- func (a *LocalDir) FetchArchive(ctx context.Context, name, version string, platform fetcher.Platform) (io.ReadCloser, int64, error)
- func (a *LocalDir) FetchSource(ctx context.Context, name, version string) (io.ReadCloser, int64, error)
- func (a *LocalDir) Info(ctx context.Context, pkgName string) (*Package, error)
- func (a *LocalDir) List(ctx context.Context) ([]string, error)
- func (a *LocalDir) ListVersions(ctx context.Context, pkgName string) ([]string, error)
- type MkdirAction
- type Multi
- func (m *Multi) Latest(ctx context.Context, pkgName string) (string, Entry, error)
- func (m *Multi) Locate(ctx context.Context, pkgName string) (Entry, *Package, error)
- func (m *Multi) Search(ctx context.Context, query string) []SearchResult
- func (m *Multi) UpdateAll(ctx context.Context) []UpdateResult
- func (m *Multi) UpdateOne(ctx context.Context, name string) error
- func (m *Multi) VersionsOf(ctx context.Context, pkgName string) []VersionResult
- type Package
- type Phase
- type PhaseSteps
- type Reporter
- type RunAction
- type SearchResult
- type Source
- type Step
- type UpdateResult
- type Updater
- type VersionEntry
- type VersionResult
Constants ¶
View Source
const PackagesSubdir = "pkgs"
On-disk layout: <repoRoot>/<PackagesSubdir>/<name>/pkg.yaml.
Variables ¶
View Source
var ErrPackageNotFound = errors.New("package not found in catalog")
Functions ¶
This section is empty.
Types ¶
type CopyAction ¶
type ExtractAction ¶
type Git ¶
type Git struct {
// contains filtered or unexported fields
}
func (*Git) FetchArchive ¶
func (*Git) FetchSource ¶
func (*Git) ListVersions ¶
type LocalDir ¶
type LocalDir struct {
// contains filtered or unexported fields
}
func (*LocalDir) FetchArchive ¶
func (*LocalDir) FetchSource ¶
type MkdirAction ¶
type MkdirAction struct {
Path string `yaml:"path"`
}
type Multi ¶
type Multi struct {
// contains filtered or unexported fields
}
func (*Multi) VersionsOf ¶
func (m *Multi) VersionsOf(ctx context.Context, pkgName string) []VersionResult
type Package ¶
type Package struct {
Name string `yaml:"name"`
Description string `yaml:"description"`
License string `yaml:"license"`
Homepage string `yaml:"homepage"`
DependsOn []string `yaml:"dependsOn"`
BuildFromSource bool `yaml:"buildFromSource"`
Archive *fetcher.Artifact `yaml:"archive,omitempty"`
Source *fetcher.Artifact `yaml:"source,omitempty"`
Versions []VersionEntry `yaml:"versions"`
Build []Step `yaml:"build,omitempty"`
Install []Step `yaml:"install,omitempty"`
Test []Step `yaml:"test,omitempty"`
}
func (*Package) Phases ¶
func (p *Package) Phases() []PhaseSteps
type Phase ¶
type Phase string
Closed set; declarative.go and the linter iterate Phases() in order — keep in sync.
type PhaseSteps ¶
type SearchResult ¶
type Source ¶
type Source interface {
List(ctx context.Context) ([]string, error)
ListVersions(ctx context.Context, pkgName string) ([]string, error)
Info(ctx context.Context, pkgName string) (*Package, error)
FetchArchive(ctx context.Context, name, version string, platform fetcher.Platform) (io.ReadCloser, int64, error)
FetchSource(ctx context.Context, name, version string) (io.ReadCloser, int64, error)
}
type Step ¶
type Step struct {
Extract *ExtractAction `yaml:"extract,omitempty"`
Copy *CopyAction `yaml:"copy,omitempty"`
Mkdir *MkdirAction `yaml:"mkdir,omitempty"`
Run *RunAction `yaml:"run,omitempty"`
}
type UpdateResult ¶
type VersionEntry ¶
type VersionResult ¶
Click to show internal directories.
Click to hide internal directories.