Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChdirStep ¶
type ChdirStep struct {
Path string
}
ChdirStep handles changing the current working directory.
type Context ¶
type Context interface {
AddProcessKillChannel(chan Result)
RemoveProcessKillChannel(chan Result)
GetProcessKillChannels() []chan Result
GetEnv() []string
AddEnv(...string)
RunTask(string) chan Result
WorkingDirectory() string
SetWorkingDirectory(string)
UpdateWorkingDirectory(string)
}
Context is an interface to Context.
type ExistsStep ¶
type ExistsStep struct {
Path string
}
ExistsStep handles checking if a directory or file exists.
func (ExistsStep) Run ¶
func (s ExistsStep) Run(pr Result) chan Result
Run checks if the file or folder exists and returns an fs.FileInfo.
type NoStep ¶ added in v0.3.0
type NoStep struct {
}
NoStep represents the beginning of a no response to a prompt.
type ParallelStep ¶ added in v0.2.0
type ParallelStep struct {
TaskNames []string
}
ParallelStep runs tasks in parallel.
func (ParallelStep) Run ¶ added in v0.2.0
func (s ParallelStep) Run(r Result) chan Result
Run uses wait groups.
type PrintStep ¶ added in v0.3.0
type PrintStep struct {
Args []interface{}
}
PrintStep handles printing passed arguments or the results of the previous step if no arguments are passed.
type PromptStep ¶ added in v0.3.0
type PromptStep struct {
Message string
}
PromptStep handles printing passed arguments or the results of the previous step if no arguments are passed.
func (PromptStep) Run ¶ added in v0.3.0
func (s PromptStep) Run(r Result) chan Result
Run prints the contents of the print step.
type ResultStep ¶
type ResultStep struct {
Func func(interface{})
}
ResultStep handles the result of a previous step.
func (ResultStep) Run ¶
func (s ResultStep) Run(r Result) chan Result
Run calls the step's result function.