Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type File ¶
type File struct {
PathTemplateConf string `yaml:"-" validate:"required,file"`
PathUserConf string `yaml:"-" validate:"required,file"` // Path to configuration file
Stderr io.Writer `yaml:"-" validate:"required"`
RepoURLs []string `yaml:"repos,omitempty"` // URLs to repo git repositories
Templates []Template `yaml:"-"` // Template definitions
}
File configuration as loaded from the configuration file
func (*File) AppendTemplate ¶
AppendTemplate appends a template to list of templates. If stop is non zero, the calling function should exit the program with the value contained in stop.
func (*File) SaveTemplates ¶
SaveTemplates saves template configuration file to disk
type FileIface ¶
type FileIface interface {
// AppendTemplate appends a template to list of templates.
// If stop is non zero, the calling function should exit the program with the
// value contained in stop.
AppendTemplate(t Template) (err error)
// Load loads configuration file from disk
Load() error
// SaveTemplates saves template configuration file to disk
SaveTemplates() error
}
FileIface ...
type SortByName ¶
type SortByName []Template
SortByName sort template alphabetically by name
func (SortByName) Len ¶
func (a SortByName) Len() int
func (SortByName) Less ¶
func (a SortByName) Less(i, j int) bool
func (SortByName) Swap ¶
func (a SortByName) Swap(i, j int)
Click to show internal directories.
Click to hide internal directories.