Documentation
¶
Overview ¶
Package context helps to populate the application context.
The main goal of the application context is to gather all the data which will be applied to a data-driven template.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OrbitContext ¶
type OrbitContext struct {
// TemplateFilePath is the path of the data-driven template.
TemplateFilePath string
// Values map contains data from YAML files.
Values map[string]interface{}
// EnvFiles map contains pairs from .env files.
EnvFiles map[string]map[string]string
// RawData contains data past directly in the CLI.
RawData map[string]string
// Os is the OS name at runtime.
Os string
}
OrbitContext contains the data necessary for executing a data-driven template.
func NewOrbitContext ¶
func NewOrbitContext(templateFilePath string, valuesFiles string, envFiles string, rawData string) (*OrbitContext, error)
NewOrbitContext instantiates a new OrbitContext.
type OrbitFileMap ¶
type OrbitFileMap struct {
// Name is the given name of the file.
Name string
// Path is the path of the file.
Path string
}
OrbitFileMap represents a value given to some flags of generate and run commands. Flags: -v --values, -e --env Value format: name,path;name,path;...
Click to show internal directories.
Click to hide internal directories.