runner

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package runner provides functions for running tasks in a tasks.yaml

Package runner provides functions for running tasks in a tasks.yaml

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExecAction added in v0.2.0

func ExecAction(ctx context.Context, cfg types.ActionDefaults, cmd string, shellPref exec.ShellPreference, spinner helpers.ProgressWriter) (string, error)

ExecAction executes the given action configuration with the provided context

func GetBaseActionCfg added in v0.2.0

func GetBaseActionCfg[T any](cfg types.ActionDefaults, a types.BaseAction[T], vars variables.SetVariableMap[T]) types.ActionDefaults

GetBaseActionCfg merges the ActionDefaults with the BaseAction's configuration

func GetMaruVariableConfig added in v0.2.0

func GetMaruVariableConfig() *variables.VariableConfig[variables.ExtraVariableInfo]

GetMaruVariableConfig gets the variable configuration for Maru

func LoadIncludeTask added in v0.5.0

func LoadIncludeTask(currentFileLocation, includeFileLocation string, auth map[string]string) (string, types.TasksFile, error)

LoadIncludeTask loads an included task file either from a remote or local file

func Run

func Run(tasksFile types.TasksFile, taskName string, setVariables map[string]string, dryRun bool, auth map[string]string) error

Run runs a task from tasks file

func RunAction added in v0.2.0

func RunAction[T any](action *types.BaseAction[T], envFilePath string, variableConfig *variables.VariableConfig[T], dryRun bool) error

RunAction executes a specific action command, either wait or cmd. It handles variable loading environment variables and manages retries and timeouts

Types

type Runner

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

Runner holds the necessary data to run tasks from a tasks file

Jump to

Keyboard shortcuts

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