Documentation
¶
Index ¶
Constants ¶
View Source
const CustomRulesFilterName = "custom-rules"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Instance ¶
type List ¶
type Parameter ¶ added in v0.29.0
type Parameter struct {
Name string `validate:"required"`
Description string `validate:"required"`
Link string `validate:"omitempty,url" yaml:",omitempty"`
Type ParamType `validate:"required,oneof=checkbox string list multiline"`
OnlyIf string `validate:"omitempty,valid_only_if" yaml:",omitempty"`
Default interface{} `validate:"valid_default"`
Presets []Preset `validate:"omitempty,preset_allowed,dive" yaml:",omitempty"`
}
func (*Parameter) BuildPresetParamName ¶ added in v0.29.0
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
Repository holds parsed Templates ready for use
func Load ¶ added in v0.29.0
func Load(templates, presets fs.FS) (*Repository, error)
Load parses template definitions from the given filesystem
func (*Repository) GetAll ¶ added in v0.29.0
func (r *Repository) GetAll() []*Template
func (*Repository) GetTags ¶
func (r *Repository) GetTags() []string
type Template ¶ added in v0.29.0
type Template struct {
Name string `validate:"required" yaml:"-"`
Title string `validate:"required"`
Params []Parameter `validate:"dive" yaml:",omitempty"`
Tags []string `validate:"dive,alphaunicode" yaml:",omitempty"`
Template string `validate:"required"`
Tests []testCase
Description string `validate:"required" yaml:"-"`
// contains filtered or unexported fields
}
type TestModeTransformer ¶ added in v0.21.0
type TestModeTransformer struct {
// contains filtered or unexported fields
}
func NewTestModeTransformer ¶ added in v0.21.0
func NewTestModeTransformer(out io.Writer) *TestModeTransformer
Click to show internal directories.
Click to hide internal directories.