intrinsic

package
v0.13.1 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2018 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Overview

Package intrinsic contains the intrinsic commands

Index

Constants

This section is empty.

Variables

View Source
var (
	// Tasks is a map of intrinsic tasks.
	Tasks = map[string]tasks.Task{
		"clean":  &Clean{},
		"extend": &Extend{},
	}
)

Functions

This section is empty.

Types

type Clean

type Clean struct {
	Files yaml.StringOrSlice `yaml:"files"`
}

Clean represents a clean task.

func (*Clean) Execute

func (c *Clean) Execute(name string, logger *gomol.LogAdapter, env []string, st *state.State) error

Execute runs the clean task.

func (*Clean) New

func (c *Clean) New() tasks.Task

New creates a new clean task.

func (*Clean) Valid

func (c *Clean) Valid() error

Valid validates the clean task.

type Extend added in v0.10.0

type Extend struct {
	Task            string             `yaml:"task"`
	Environment     yaml.StringOrSlice `yaml:"environment"`
	Expand          yaml.StringOrSlice `yaml:"expand"`
	ExpandDelimiter string             `yaml:"expand_delimiter"`

	// A copy of the extended task. Must be public so that deepcopy
	// can serialize it properly in case an extended task is extended
	// itself (when private the innerTask is nil and causes a bad
	// data access exception).
	InnerTask tasks.Task
}

Extend represents a task that extends another task.

func (*Extend) Dependencies added in v0.10.0

func (e *Extend) Dependencies() []string

Dependencies returns a list of tasks that this task depends on.

func (*Extend) Execute added in v0.10.0

func (e *Extend) Execute(name string, logger *gomol.LogAdapter, env []string, st *state.State) error

Execute runs an extended task.

func (*Extend) New added in v0.10.0

func (e *Extend) New() tasks.Task

New creates a new extend task.

func (*Extend) Resolve added in v0.10.0

func (e *Extend) Resolve(taskMap map[string]tasks.Task) error

Resolve returns the fully extended task.

func (*Extend) Valid added in v0.10.0

func (e *Extend) Valid() error

Valid validates the task.

Jump to

Keyboard shortcuts

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