Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildOptions ¶
func NewBuildOptions ¶
func NewBuildOptions(version, configPathBase string) BuildOptions
type ConfigPath ¶
type ExecutionContext ¶
type ExecutionContext struct { // CMDName is the name of CMD (os.Args[0]). To be filled in later to // correctly render example strings etc. CMDName string Stderr, Stdout io.Writer // ID is a unique ID for this Execution ID string // IsTerminal indicates whether the current session is a terminal or not IsTerminal bool // LogLevel indicates the logrus default logging level LogLevel string // NoColor indicates if the outputs shouldn't be colorized NoColor bool // Logger is the global logger object to print logs. Logger *logrus.Logger // Spinner is the global spinner object used to show progress across the cli. Spinner *spinner.Spinner // Version is the parsed semantic version for CLI Version string // Viper indicates the viper object for the execution Viper *viper.Viper GlobalConfig *GlobalConfig // contains filtered or unexported fields }
func NewExecutionContext ¶
func NewExecutionContext(bo BuildOptions) *ExecutionContext
func (*ExecutionContext) Prepare ¶
func (ec *ExecutionContext) Prepare() error
Prepare as the name suggests, prepares the ExecutionContext ec by initializing most of the variables to sensible defaults, if it is not already set.
func (*ExecutionContext) Spin ¶
func (ec *ExecutionContext) Spin(message string)
Spin stops any existing spinner and starts a new one with the given message.
type GlobalConfig ¶
type GlobalConfig struct {
HasuraenvPath ConfigPath
}
Source Files ¶
Click to show internal directories.
Click to hide internal directories.