domain

package
v1.7.0-2 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Arg added in v1.6.0

type Arg struct {
	Name       string
	Usage      string
	Default    string
	InputEnvs  []string `yaml:"input_envs"`
	ScriptEnvs []string `yaml:"script_envs"`
	Required   bool
	Prompt     prompt.Prompt
	Validate   []Validate
}

type Config added in v1.6.0

type Config struct {
	Tasks       []Task
	InputEnvs   []string `yaml:"input_envs"`
	ScriptEnvs  []string `yaml:"script_envs"`
	Environment map[string]string
	Timeout     Timeout
	Quiet       *bool
}

type Flag added in v1.6.0

type Flag struct {
	Name       string
	Short      string
	Usage      string
	Default    string
	InputEnvs  []string `yaml:"input_envs"`
	ScriptEnvs []string `yaml:"script_envs"`
	Type       string
	Required   bool
	Prompt     prompt.Prompt
	Validate   []Validate
}

type GlobalFlags added in v1.6.0

type GlobalFlags struct {
	DryRun     bool
	Quiet      *bool
	WorkingDir string
}

type HasIsSet added in v1.6.0

type HasIsSet interface {
	IsSet(string) bool
}

type Require added in v1.6.0

type Require struct {
	Exec        []StrList
	Environment []StrList
}

type StrList added in v1.6.0

type StrList []string

func (*StrList) UnmarshalYAML added in v1.6.0

func (list *StrList) UnmarshalYAML(unmarshal func(interface{}) error) error

type Task added in v1.6.0

type Task struct {
	Name        string
	Short       string
	Description string
	Usage       string
	Flags       []Flag
	Args        []Arg
	InputEnvs   []string `yaml:"input_envs"`
	ScriptEnvs  []string `yaml:"script_envs"`
	Environment map[string]string
	Script      string
	Timeout     Timeout
	Require     Require
	Quiet       *bool
	Shell       []string
	Tasks       []Task
}

type Timeout added in v1.6.0

type Timeout struct {
	Duration  int
	KillAfter int `yaml:"kill_after"`
}

type Validate added in v1.6.0

type Validate struct {
	Type      string
	RegExp    string `yaml:"regexp"`
	MinLength int    `yaml:"min_length"`
	MaxLength int    `yaml:"max_length"`
	Prefix    string
	Suffix    string
	Contain   string
	Enum      []string

	Min int
	Max int
}

Jump to

Keyboard shortcuts

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