core

package
v0.0.0-...-1edb202 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPClient

type HTTPClient interface {
	Get(url string) (resp *http.Response, err error)
}

type Package

type Package struct {
	Name  string
	Alias string
	URL   string
}

type Pkgfy

type Pkgfy struct {
	Config PkgfyConfig
	Client *HTTPClient
}

func (*Pkgfy) Install

func (p *Pkgfy) Install(pkg Package) (err error)

Install downloads the given url and saves it in the config.InstallDir with pkg.Name. It creates the config.InstallDir if needed. The file mode for the created dir and file is 0755.

type PkgfyConfig

type PkgfyConfig struct {
	InstallDir string
}

Jump to

Keyboard shortcuts

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