builtin

package
v0.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2021 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAll

func RegisterAll(mc rocket.MissionControl)

RegisterAll all built in task types with the passed mission control.

Types

type Cleaner

type Cleaner struct {
	Files []string `mapstructure:"files"`
	Log   bool     `mapstructure:"log"`
}

Cleaner task is used to run a specific task.

type Fetch

type Fetch struct {
	Resources []FetchResource `mapstructure:"resources"`
	Log       bool            `mapstructure:"log"`
	Timeout   *int            `mapstructure:"timeout"`
}

Fetch task is used get one or more web resources.

type FetchResource

type FetchResource struct {
	URL    string `mapstructure:"url"`
	Output string `mapstructure:"output"`
}

type MkDir

type MkDir struct {
	Dirs []string `mapstructure:"dirs"`
	Log  bool     `mapstructure:"log"`
}

MkDir task is used create directories.

type Run

type Run struct {

	// Command to execute.  This is a raw executed command and is not
	// wrapped ina shell, as such globing etc may not work as expected.
	// Command is subject to string expansion.
	Command string `mapstructure:"command"`

	// List of arguments, subject to string expansion.
	Args []string `mapstructure:"args"`

	// GlobArgs specifies if arguments should be glob expanded prior
	// to passing the program.  If true *.go would ne expanded as a arg per matching file.
	GlobArgs bool `mapstructure:"glob"`

	// Redirect handles input and output redirection.
	rocket.Redirection `mapstructure:",squash"`

	// LogOutput if true will cause output to be logged rather than going to go to std output.
	// If an output file is specified it will be used instead.
	LogOutput bool `mapstructure:"logStdOut"`

	// DirectError when true causes the commands std error output to go direct to running processes std error
	// When DirectError is false std error output is logged.
	DirectError bool `mapstructure:"directStdErr"`
}

Run task is used to run a specific task.

type Template

type Template struct {
	// Template file
	FileTemplate      string `mapstructure:"template"`
	InlineTemplate    string `mapstructure:"inline"`
	rocket.OutputSpec `mapstructure:",squash"`
	Delims            rocket.Delims `mapstructure:"delims"`
}

Template is a task to expand the input file using the Template file. Output is written to the redirected STDOUT Delims is used to change the standard golang templatiing delimiters This can be useful when processing a source file that itself uses golang tempalting.

Jump to

Keyboard shortcuts

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