Versions in this module Expand all Collapse all v0 v0.7.1 Nov 9, 2025 v0.7.0 Nov 1, 2025 Changes in this version + var ErrNoCommandsToExecute = errors.New("no commands to execute") + func GenerateJSONSchema() ([]byte, error) + func ParseDuration(s string) (time.Duration, error) + func SaveSchemaToFile(filename string) error + func Validate(config *SetupConfig) error + type APIClientInterface interface + GetSecret func(orgSlug, projectSlug, secretKey string) (*types.SecretWithValue, error) + GetWrappedProjectKey func(orgSlug, projectSlug string) (string, error) + type ActionFactory struct + func NewActionFactory() *ActionFactory + func (f *ActionFactory) BuildFromStep(step *Step) (actions.Action, error) + type AptInstall struct + Packages []string + Update bool + type AssertHTTP struct + ExpectStatus int + Retries *Retries + URL string + type BrewInstall struct + Formula string + type ChocoInstall struct + Packages []string + type CommandExecutor interface + Execute func(ctx context.Context, req *CommandRequest) error + func NewRealCommandExecutor() CommandExecutor + type CommandRequest struct + Args []string + Command string + Env map[string]string + Timeout time.Duration + WorkingDir string + type ConditionEvaluator struct + Arch string + Env map[string]string + OS string + func NewConditionEvaluator(os, arch string, env map[string]string) *ConditionEvaluator + func (e *ConditionEvaluator) Evaluate(condition string) (bool, error) + func (e *ConditionEvaluator) ShouldExecuteStep(step *Step) (bool, error) + type Context struct + Arch string + OS string + Secrets map[string]string + WorkingDir string + func NewContext() (*Context, error) + func (c *Context) ShouldExecuteStep(step *Step) (bool, error) + func (c *Context) WithSecrets(secrets map[string]string) *Context + func (c *Context) WithWorkingDir(dir string) (*Context, error) + type Defaults struct + CWD string + ContinueOnError bool + Shell string + Timeout string + type EnsureDatabase struct + CreateDB []string + Engine string + EnsureRunning bool + ServiceName string + Version string + type EnsurePackageManager struct + Type string + type EnsureRuntime struct + FallbackInstallers []RuntimeFallbackInstaller + Manager *RuntimeManager + Name string + Version string + type EnsureTool struct + Install *ToolInstallConfig + Name string + Version string + type Environment struct + Secrets []string + Vars map[string]string + type ExecutableCommand struct + Args []string + Command string + ContinueOnError bool + Description string + Env map[string]string + Phase string + Retries *RetryPolicy + StepIndex int + StepName string + Timeout time.Duration + WorkingDir string + type ExecutionPlan struct + Commands []ExecutableCommand + Summary ExecutionSummary + func Render(config *SetupConfig, ctx *RenderContext) (*ExecutionPlan, error) + type ExecutionSummary struct + Phases []PhaseSummary + TotalCommands int + TotalSteps int + type Executor struct + func NewExecutor(secrets map[string]string) *Executor + func NewExecutorWithCommandExecutor(secrets map[string]string, executor CommandExecutor) *Executor + func (e *Executor) Execute(plan *ExecutionPlan) error + type Matrix struct + Arch []string + OS []string + type MatrixMatcher struct + Arch string + OS string + func NewMatrixMatcher() *MatrixMatcher + func (m *MatrixMatcher) GetCurrentPlatform() string + func (m *MatrixMatcher) GetSupportedPlatforms(config *SetupConfig) []string + func (m *MatrixMatcher) IsCurrentPlatformSupported(config *SetupConfig) (bool, error) + func (m *MatrixMatcher) Matches(config *SetupConfig) (bool, error) + type ParsedDuration struct + Duration time.Duration + Original string + type ParsedRetries struct + Attempts int + Backoff time.Duration + Original Retries + type Phase struct + Name string + Steps []Step + func GetAllPhases(config *SetupConfig) []Phase + type PhaseSummary struct + CommandCount int + Name string + StepCount int + type RenderContext struct + Arch string + DefaultContinueOnError bool + DefaultTimeout time.Duration + GlobalEnv map[string]string + OS string + Secrets map[string]string + Shell string + WorkingDir string + type Retries struct + Attempts int + Backoff string + type RetryPolicy struct + Attempts int + Backoff time.Duration + func ParseRetryPolicy(retries *Retries) *RetryPolicy + type RuntimeFallbackInstaller struct + Apt *AptInstall + Brew *BrewInstall + Choco *ChocoInstall + type RuntimeManager struct + Asdf bool + type SetupConfig struct + Bootstrap []Step + Defaults *Defaults + Description string + Env *Environment + Matrix *Matrix + Name string + Post []Step + Provision []Step + Setup []Step + Verify []Step + Version int + func Parse(data []byte) (*SetupConfig, error) + func ParseFile(filename string) (*SetupConfig, error) + func ParseFromReader(reader io.Reader) (*SetupConfig, error) + type SetupRunner struct + func NewSetupRunner(projectCtx *config.ProjectContext) *SetupRunner + func NewSetupRunnerWithDeps(projectCtx *config.ProjectContext, store StorageInterface, ...) *SetupRunner + func (r *SetupRunner) Run(config *SetupConfig) error + type Step struct + AssertCommand string + AssertHTTP *AssertHTTP + CWD string + ContinueOnError bool + EnsureDatabase *EnsureDatabase + EnsurePackageManager *EnsurePackageManager + EnsureRuntime *EnsureRuntime + EnsureTool *EnsureTool + Env map[string]string + EnvFromSecrets []string + If string + Name string + OptionalSecrets bool + Print string + Retries *Retries + Run string + Timeout string + type StorageInterface interface + GetEncryptionPrivateKey func() ([]byte, error) + HasDeviceID func() bool + type ToolInstallConfig struct + Apt *AptInstall + Brew *BrewInstall + Checksum string + Choco *ChocoInstall + FallbackURL string + type ValidationError struct + Field string + Message string + func (e ValidationError) Error() string + type ValidationErrors []ValidationError + func (e ValidationErrors) Error() string