Documentation
¶
Index ¶
- type ConfigInfoResult
- type ConfigService
- func (s ConfigService) AddPackage(repo, name string, opts install.Options) error
- func (s ConfigService) ConfigGet(key string) (string, error)
- func (s ConfigService) ConfigInfo() (ConfigInfoResult, error)
- func (s ConfigService) ConfigInit() (string, error)
- func (s ConfigService) ConfigList() (*cfgpkg.File, error)
- func (s ConfigService) ConfigSet(key, value string) error
- type InstallExtras
- type InstalledLoader
- type InstalledStore
- type Installer
- type ListItem
- type ListService
- type OutdatedCheckFailure
- type OutdatedItem
- type PackageAdder
- type QueryAsset
- type QueryClient
- type QueryOptions
- type QueryRelease
- type QueryRepoInfo
- type QueryResult
- type QueryService
- type ReleaseInfoFunc
- type RemovableInstalledStore
- type RunResult
- type Runner
- type Service
- type UninstallResult
- type UninstallService
- type UpdateResult
- type UpdateService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigInfoResult ¶
type ConfigService ¶
type ConfigService struct {
ConfigPath string
Load func() (*cfgpkg.File, error)
Save func(path string, file *cfgpkg.File) error
}
func (ConfigService) AddPackage ¶
func (s ConfigService) AddPackage(repo, name string, opts install.Options) error
func (ConfigService) ConfigInfo ¶
func (s ConfigService) ConfigInfo() (ConfigInfoResult, error)
func (ConfigService) ConfigInit ¶
func (s ConfigService) ConfigInit() (string, error)
func (ConfigService) ConfigList ¶
func (s ConfigService) ConfigList() (*cfgpkg.File, error)
func (ConfigService) ConfigSet ¶
func (s ConfigService) ConfigSet(key, value string) error
type InstallExtras ¶
type InstalledLoader ¶
type InstalledStore ¶
type ListService ¶
type ListService struct {
LoadConfig func() (*cfgpkg.File, error)
LoadInstalled func() (*storepkg.Config, error)
LatestTag func(repo string) (string, error)
}
func (ListService) FindPackage ¶ added in v1.5.1
func (s ListService) FindPackage(name string) (*ListItem, error)
func (ListService) ListOutdatedPackages ¶ added in v1.5.1
func (s ListService) ListOutdatedPackages() ([]OutdatedItem, []OutdatedCheckFailure, error)
func (ListService) ListPackages ¶
func (s ListService) ListPackages() ([]ListItem, error)
type OutdatedCheckFailure ¶ added in v1.5.1
type OutdatedItem ¶ added in v1.5.1
type PackageAdder ¶
type QueryAsset ¶ added in v1.5.1
type QueryClient ¶ added in v1.5.1
type QueryClient interface {
RepoInfo(repo string) (QueryRepoInfo, error)
LatestRelease(repo string, includePrerelease bool) (QueryRelease, error)
ListReleases(repo string, limit int, includePrerelease bool) ([]QueryRelease, error)
ReleaseAssets(repo, tag string) ([]QueryAsset, error)
}
type QueryOptions ¶ added in v1.5.1
type QueryRelease ¶ added in v1.5.1
type QueryRepoInfo ¶ added in v1.5.1
type QueryRepoInfo struct {
Repo string `json:"repo"`
Description string `json:"description,omitempty"`
Homepage string `json:"homepage,omitempty"`
DefaultBranch string `json:"default_branch,omitempty"`
Stars int `json:"stars,omitempty"`
Forks int `json:"forks,omitempty"`
OpenIssues int `json:"open_issues,omitempty"`
UpdatedAt time.Time `json:"updated_at,omitempty"`
}
type QueryResult ¶ added in v1.5.1
type QueryResult struct {
Action string `json:"action"`
Repo string `json:"repo"`
Tag string `json:"tag,omitempty"`
Info *QueryRepoInfo `json:"info,omitempty"`
Latest *QueryRelease `json:"latest,omitempty"`
Releases []QueryRelease `json:"releases,omitempty"`
Assets []QueryAsset `json:"assets,omitempty"`
}
func (QueryResult) JSONString ¶ added in v1.5.1
func (r QueryResult) JSONString() (string, error)
type QueryService ¶ added in v1.5.1
type QueryService struct {
Client QueryClient
}
func (QueryService) Query ¶ added in v1.5.1
func (s QueryService) Query(opts QueryOptions) (QueryResult, error)
type RemovableInstalledStore ¶
type Service ¶
type Service struct {
Runner Runner
Store InstalledStore
Config PackageAdder
Now func() time.Time
ReleaseInfo ReleaseInfoFunc
LoadConfig func() (*cfgpkg.File, error)
}
func (Service) DownloadTarget ¶
func (Service) InstallTarget ¶
type UninstallResult ¶
type UninstallService ¶
type UninstallService struct {
Store RemovableInstalledStore
LoadConfig func() (*cfgpkg.File, error)
}
func (UninstallService) Uninstall ¶
func (s UninstallService) Uninstall(target string) (UninstallResult, error)
type UpdateResult ¶
type UpdateService ¶
func (UpdateService) UpdateAllPackages ¶
func (s UpdateService) UpdateAllPackages(cli install.Options) ([]UpdateResult, error)
func (UpdateService) UpdatePackage ¶
Click to show internal directories.
Click to hide internal directories.