Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( ErrReload = errors.New("reloading config") ErrLiveTheme = errors.New("cannot make changes to a live theme without an override") ErrDuringRuntime = errors.New("finished command with errors") )
ErrReload is an error to return from a command if you want to reload and run again
Functions ¶
func ForDefaultClient ¶
ForDefaultClient will run in a context that runs of any available config including defaults
func ForEachClient ¶
ForEachClient will generate a command context for all the available environments and run a command in each of those contexts
func ForSingleClient ¶
ForSingleClient will generate a command context for all the available environments, and run a command for the first context. If more than one environment was specified, then an error will be returned.
Types ¶
type Ctx ¶
type Ctx struct {
Shop shopify.Shop
Conf config
Client shopifyClient
Flags Flags
Env *env.Env
Args []string
Log *log.Logger
ErrLog *log.Logger
Bar *mpb.Bar
// contains filtered or unexported fields
}
Ctx is a specific context that a command will run in
func (*Ctx) DisableSummary ¶ added in v1.1.3
func (ctx *Ctx) DisableSummary()
DisableSummary will ensure that the file operation summary will not output at the end of the operation
func (*Ctx) DoneTask ¶
DoneTask will mark one unit of work complete. If the context has a progress bar then it will increment it.
func (*Ctx) StartProgress ¶
StartProgress will create a new progress bar for the running context with the total amount of tasks as the count
type Flags ¶
type Flags struct {
ConfigPath string
VariableFilePath string
Environments []string
Directory string
Password string
ThemeID string
Domain string
Proxy string
Timeout time.Duration
Verbose bool
DisableUpdateNotifier bool
IgnoredFiles []string
Ignores []string
DisableIgnore bool
Notify string
AllEnvs bool
Version string
Prefix string
URL string
Name string
Edit bool
With string
List bool
NoDelete bool
AllowLive bool
Live bool
HidePreviewBar bool
DisableThemeKitAccessNotifier bool
}
Flags encapsulates all the possible flags that can be set in the themekit command line. Some of the values are used across different commands