config

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cfg

type Cfg struct {
	Version     string      `json:"version"`
	ProjectName string      `json:"projectName"`
	BaseUrl     string      `json:"baseUrl"`
	BeforeRun   []string    `json:"beforeRun"`
	Flows       []*app.Flow `json:"flows"`
	AfterRun    []string    `json:"afterRun"`
	// contains filtered or unexported fields
}

func LoadConfig

func LoadConfig(path string) (*Cfg, error)

func NewDefaultConfig

func NewDefaultConfig(baseUrl string) (Cfg, error)

func (*Cfg) AddFlow

func (self *Cfg) AddFlow(flow *app.Flow) error

func (*Cfg) GetConfigDir

func (self *Cfg) GetConfigDir() string

GetConfigDir returns the directory containing the config file. Used for resolving relative file paths in file uploads.

func (*Cfg) GetFlow

func (self *Cfg) GetFlow(name string) (*app.Flow, bool)

GetFlow returns a pointer to the named flow with a boolean 'ok' if it's found.

func (*Cfg) GetTotalSteps

func (self *Cfg) GetTotalSteps() int

func (*Cfg) RemoveFlow

func (self *Cfg) RemoveFlow(flowName string) error

func (*Cfg) Save

func (self *Cfg) Save() error

func (*Cfg) UpdateFlow

func (self *Cfg) UpdateFlow(flow *app.Flow) error

Jump to

Keyboard shortcuts

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