exec

package
v1.5.0-alpha8 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2024 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrUnknownTemplate

func ErrUnknownTemplate(name string) error

func ExtractUnknownArgs

func ExtractUnknownArgs(flags *pflag.FlagSet, args []string) []string

ExtractUnknownArgs extracts any long-form flags (--something) that are not currently configured for this command, they must be flags intended for the custom job type.

func NewCmd

func NewCmd() *cobra.Command

func NewCmdWithOptions

func NewCmdWithOptions(options *ExecOptions) *cobra.Command

func PrepareJob

func PrepareJob(cmd *cobra.Command, cmdArgs []string, unknownArgs []string, options *ExecOptions) (*models.Job, error)

Types

type ExecOptions

type ExecOptions struct {
	JobSettings     *cliflags.JobSettings
	TaskSettings    *cliflags.TaskSettings
	RunTimeSettings *cliflags.RunTimeSettings
	Code            string
}

func NewExecOptions

func NewExecOptions() *ExecOptions

type TemplateMap

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

func NewTemplateMap

func NewTemplateMap(fsys fs.ReadDirFS, tplPath string) (*TemplateMap, error)

func (*TemplateMap) AllTemplates

func (t *TemplateMap) AllTemplates() []string

func (*TemplateMap) Get

func (t *TemplateMap) Get(name string) (string, error)

Jump to

Keyboard shortcuts

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