harness

package
v0.3.6-beta Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2024 License: BSD-2-Clause-Patent Imports: 17 Imported by: 0

Documentation

Overview

Package harness provides support for executing Harness plugins.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Is

func Is(root string) bool

Is returns true if the root path is a Harness plugin repository.

func Lookup

func Lookup(name, version string) (repo string, ref string, commit string, ok bool)

Lookup returns the repository and commit associated with the named step and version.

func ParseLookup

func ParseLookup(s string) (repo string, ref string, commit string, ok bool)

ParseLookup parses the step string and returns the associated repository and commit.

Types

type Apt

type Apt struct {
	Packages []string     `yaml:"packages,omitempty"`
	Sources  []*AptSource `yaml:"sources,omitempty"`
}

spec defines the bitrise plugin.

func (*Apt) UnmarshalYAML

func (v *Apt) UnmarshalYAML(unmarshal func(interface{}) error) error

UnmarshalYAML implements the unmarshal interface.

type AptSource

type AptSource struct {
	Key  string `yaml:"key,omitempty"`
	Data string `yaml:"line,omitempty"`
}

spec defines the bitrise plugin.

type Execer

type Execer struct {
	Ref          string // Git ref for source code
	Source       string // plugin source code directory
	Workdir      string // pipeline working directory (aka workspace)
	DownloadOnly bool
	Environ      []string
	Stdout       io.Writer
	Stderr       io.Writer
}

Execer executes a harness plugin.

func (*Execer) Exec

func (e *Execer) Exec(ctx context.Context) error

Exec executes a bitrise plugin.

type Metadata

type Metadata struct {
	// contains filtered or unexported fields
}

Metadata implements a source url generator that uses a template engine to generate url from give metadata.

func NewMetadata

func NewMetadata(tmpl string, ref string) *Metadata

NewMetadata creates a new source Generator.

func (*Metadata) Generate

func (g *Metadata) Generate() (string, error)

Generate generates url from given template.

Jump to

Keyboard shortcuts

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