manager

package
v0.6.4 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindRoot

func FindRoot(from string, fs afero.Fs, manifest string) (string, error)

FindRoot gets a manifest file path.

Types

type Executor

type Executor interface {
	Exec(ctx context.Context, name string, args ...string) error
	Output(ctx context.Context, name string, args ...string) ([]byte, error)
}

Executor is an interface for executing managers.

func NewExecutor

func NewExecutor(exec *execx.Executor, outW, errW io.Writer, inR io.Reader, cwd string, log *log.Logger) Executor

NewExecutor creates a new Executor instance.

type Interface

type Interface interface {
	Add(ctx context.Context, pkgs []string, verbose bool) error
	Build(ctx context.Context, binPath, pkg string, verbose bool) error
	Sync(ctx context.Context, verbose bool) error
}

type Type

type Type int

Type represents the dependencies management tool that is used.

const (
	TypeUnknown Type = iota
	TypeModules
	TypeDep
)

Type values

func DetectType

func DetectType(workDir string, fs afero.Fs, exec *execx.Executor) (t Type, rootDir string)

DetectType detects a current Mode and sets a root directory.

func (Type) String

func (t Type) String() string

func (Type) Vendor

func (t Type) Vendor() bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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