Documentation
¶
Index ¶
- Constants
- Variables
- func DefaultRunE(cmd *cobra.Command, args []string) error
- func DetectShortNameCollisions(root *cobra.Command) bool
- func ExtractRootFlags(cmd *cobra.Command, args []string, flags *RootFlags) error
- func GetExecutionMode(continueOnErr bool, stopOnErr bool, rollbackOnErr bool) (automa.TypeMode, error)
- func OutputIsJSON() bool
- func RegisterHostFirewallFlags(cmd *cobra.Command)
- func RequireGlobalChecks(cmd *cobra.Command) bool
- func ResolveHostFirewallConfig(cmd *cobra.Command, args []string, cv *prompt.ChosenValues, ...) error
- func RunPersistentPreRun(cmd *cobra.Command, args []string) error
- func RunStartupMigrations(ctx context.Context) error
- func RunWorkflow(ctx context.Context, fn func() (*automa.Report, error)) error
- func RunWorkflowBuilder(ctx context.Context, b automa.Builder) error
- func SkipGlobalChecks(cmd *cobra.Command)
- type CommaSplitStringsFlagDefinition
- func (fp CommaSplitStringsFlagDefinition) Clone() CommaSplitStringsFlagDefinition
- func (fp CommaSplitStringsFlagDefinition) MarkRequired(cmd *cobra.Command, v bool) error
- func (fp CommaSplitStringsFlagDefinition) MarkRequiredP(cmd *cobra.Command, v bool) error
- func (fp CommaSplitStringsFlagDefinition) SetVar(cmd *cobra.Command, p *[]string, required bool)
- func (fp CommaSplitStringsFlagDefinition) SetVarP(cmd *cobra.Command, p *[]string, required bool)
- func (fp CommaSplitStringsFlagDefinition) SetVarPHidden(cmd *cobra.Command, p *[]string, required bool)
- func (fp CommaSplitStringsFlagDefinition) Value(cmd *cobra.Command, args []string) ([]string, error)
- func (fp CommaSplitStringsFlagDefinition) ValueLocal(cmd *cobra.Command, args []string) ([]string, error)
- func (fp CommaSplitStringsFlagDefinition) ValueOwnPersistent(cmd *cobra.Command, args []string) ([]string, error)
- type CountFlagDefinition
- type FlagDefinition
- func FlagAlloyClusterSecretStore() FlagDefinition[string]
- func FlagApplicationStatePath() FlagDefinition[string]
- func FlagApplicationStateSize() FlagDefinition[string]
- func FlagArchivePath() FlagDefinition[string]
- func FlagArchiveSize() FlagDefinition[string]
- func FlagBasePath() FlagDefinition[string]
- func FlagChartRepo() FlagDefinition[string]
- func FlagClusterName() FlagDefinition[string]
- func FlagConfig() FlagDefinition[string]
- func FlagContinueOnError() FlagDefinition[bool]
- func FlagDaemonBNOrbit() FlagDefinition[string]
- func FlagDaemonBin() FlagDefinition[string]
- func FlagDaemonCNNodeID() FlagDefinition[string]
- func FlagDaemonCNOrbit() FlagDefinition[string]
- func FlagDaemonCNUpgradeDir() FlagDefinition[string]
- func FlagDaemonChecksum() FlagDefinition[string]
- func FlagDaemonComponents() FlagDefinition[string]
- func FlagDaemonFromConfig() FlagDefinition[string]
- func FlagForce() FlagDefinition[bool]
- func FlagHistoricRetention() FlagDefinition[string]
- func FlagLivePath() FlagDefinition[string]
- func FlagLiveSize() FlagDefinition[string]
- func FlagLoadBalancerEnabled() FlagDefinition[bool]
- func FlagLogLevel() FlagDefinition[string]
- func FlagLogPath() FlagDefinition[string]
- func FlagLogSize() FlagDefinition[string]
- func FlagLokiURL() FlagDefinition[string]
- func FlagLokiUsername() FlagDefinition[string]
- func FlagMetricsServer() FlagDefinition[bool]
- func FlagMonitorBlockNode() FlagDefinition[bool]
- func FlagNamespace() FlagDefinition[string]
- func FlagNoRestart() FlagDefinition[bool]
- func FlagNoReuseValues() FlagDefinition[bool]
- func FlagNodeType() FlagDefinition[string]
- func FlagNonInteractive() FlagDefinition[bool]
- func FlagOutputFormat() FlagDefinition[string]
- func FlagPluginPreset() FlagDefinition[string]
- func FlagPlugins() FlagDefinition[string]
- func FlagPluginsPath() FlagDefinition[string]
- func FlagPluginsSize() FlagDefinition[string]
- func FlagProfile() FlagDefinition[string]
- func FlagPrometheusURL() FlagDefinition[string]
- func FlagPrometheusUsername() FlagDefinition[string]
- func FlagPurgeStorage() FlagDefinition[bool]
- func FlagRecentRetention() FlagDefinition[string]
- func FlagReleaseName() FlagDefinition[string]
- func FlagRollbackOnError() FlagDefinition[bool]
- func FlagSkipHardwareChecks() FlagDefinition[bool]
- func FlagStopOnError() FlagDefinition[bool]
- func FlagTeleportValuesFile() FlagDefinition[string]
- func FlagTeleportVersion() FlagDefinition[string]
- func FlagValuesFile() FlagDefinition[string]
- func FlagVerificationPath() FlagDefinition[string]
- func FlagVerificationSize() FlagDefinition[string]
- func FlagVersion() FlagDefinition[bool]
- func FlagWithStorageReset() FlagDefinition[bool]
- func (fp FlagDefinition[T]) Clone() FlagDefinition[T]
- func (fp FlagDefinition[T]) MarkRequired(cmd *cobra.Command, v bool) error
- func (fp FlagDefinition[T]) MarkRequiredP(cmd *cobra.Command, v bool) error
- func (fp FlagDefinition[T]) SetVar(cmd *cobra.Command, p *T, required bool)
- func (fp FlagDefinition[T]) SetVarP(cmd *cobra.Command, p *T, required bool)
- func (fp FlagDefinition[T]) SetVarPHidden(cmd *cobra.Command, p *T, required bool)
- func (fp FlagDefinition[T]) Value(cmd *cobra.Command, args []string) (T, error)
- func (fp FlagDefinition[T]) ValueLocal(cmd *cobra.Command, args []string) (T, error)
- func (fp FlagDefinition[T]) ValueOwnPersistent(cmd *cobra.Command, args []string) (T, error)
- type RepeatableStringFlagDefinition
- func (fp RepeatableStringFlagDefinition) Clone() RepeatableStringFlagDefinition
- func (fp RepeatableStringFlagDefinition) MarkRequired(cmd *cobra.Command, v bool) error
- func (fp RepeatableStringFlagDefinition) MarkRequiredP(cmd *cobra.Command, v bool) error
- func (fp RepeatableStringFlagDefinition) SetVar(cmd *cobra.Command, p *[]string, required bool)
- func (fp RepeatableStringFlagDefinition) SetVarP(cmd *cobra.Command, p *[]string, required bool)
- func (fp RepeatableStringFlagDefinition) SetVarPHidden(cmd *cobra.Command, p *[]string, required bool)
- func (fp RepeatableStringFlagDefinition) Value(cmd *cobra.Command, args []string) ([]string, error)
- func (fp RepeatableStringFlagDefinition) ValueLocal(cmd *cobra.Command, args []string) ([]string, error)
- func (fp RepeatableStringFlagDefinition) ValueOwnPersistent(cmd *cobra.Command, args []string) ([]string, error)
- type RootFlags
- type SetupResult
Constants ¶
const ( FlagNameFirewallEnabled = "firewall-enabled" FlagNameMgmtCIDRs = "mgmt-cidrs" FlagNameSSHPort = "ssh-port" FlagNamePodCIDR = "pod-cidr" FlagNameInClusterPorts = "in-cluster-ports" )
Host-firewall flag names, shared by every block-node command that can apply the node-level host firewall (install, reconfigure, upgrade). Kept in one place so the flag registration and the resolver never drift.
const KeyRequireGlobalChecks = "requireGlobalChecks"
Variables ¶
var OutputFormat string
OutputFormat holds the value of the root persistent --output/-o flag. Like ui.NonInteractive and ui.VerboseLevel, it is bound directly by the root command's SetVarP so the value is visible to this package without threading a *cobra.Command through every workflow-run call site. It selects the stdout log format: "text" (default) keeps the human-readable console / TUI, while "json" emits machine-readable NDJSON log lines plus a final summary object.
Functions ¶
func DefaultRunE ¶
DefaultRunE is a default RunE function that shows help message and provides a placeholder to add common behaviour. We always add a run function to commands to ensure cobra marks it as Runnable and allows our commands to invoke PersistentPreRunE functions of the root command.
func ExtractRootFlags ¶
ExtractRootFlags extracts the flags registered on the root command. Config and logging are already initialized by root.go's initConfig (via cobra.OnInitialize).
func GetExecutionMode ¶
func GetExecutionMode(continueOnErr bool, stopOnErr bool, rollbackOnErr bool) (automa.TypeMode, error)
GetExecutionMode determines the execution mode based on the provided flags. It ensures that only one of the flags is set; otherwise, it returns an error. The precedence is as follows: 1. continueOnErr 2. rollbackOnErr 3. stopOnErr (default)
func OutputIsJSON ¶ added in v0.22.1
func OutputIsJSON() bool
OutputIsJSON reports whether the operator requested machine-readable JSON output on stdout via --output json.
func RegisterHostFirewallFlags ¶ added in v0.22.1
RegisterHostFirewallFlags registers the node-level host firewall flags on cmd. The values are read back by name in ResolveHostFirewallConfig (no bound vars), so the same registration works for any command that provisions a host.
func RequireGlobalChecks ¶
RequireGlobalChecks checks if a command requires global pre-run checks. By default, commands require global checks unless explicitly marked to skip them.
func ResolveHostFirewallConfig ¶ added in v0.22.1
func ResolveHostFirewallConfig(cmd *cobra.Command, args []string, cv *prompt.ChosenValues, extraInputPrompts ...prompt.InputPrompt) error
ResolveHostFirewallConfig determines the effective host firewall configuration (enabled, management CIDR allowlist, SSH port, pod CIDR, in-cluster host-service ports) and applies it to the global config so the NetworkFirewallCreate step (wired into the block-node install/reconfigure/ upgrade workflows) can render the inet host table. Precedence per value: CLI flag > interactive prompt > config file > built-in default. When the session is interactive, any value not supplied on the CLI is presented as a pre-filled prompt the operator can confirm with Enter. An empty management allowlist is allowed — the step then skips firewall creation rather than rendering a lock-out (default-drop) ruleset.
When cv is non-nil the prompted values are recorded into it and no separate summary is printed — the caller is responsible for printing the unified summary after all prompt sections complete. When cv is nil a local collector is used and printed as "Host Firewall" immediately.
extraInputPrompts are prepended to the firewall input prompts so callers can place related prompts (e.g. egress interface) in the same TUI panel.
It requires RegisterHostFirewallFlags to have been called on cmd.
func RunPersistentPreRun ¶
RunPersistentPreRun is the body of the root PersistentPreRunE hook. It runs before every command and is responsible for:
- Verifying the weaver installation (skipped for commands that opt out via SkipGlobalChecks).
- Running any pending startup migrations.
func RunStartupMigrations ¶
RunStartupMigrations runs a single ordered pass over all startup-scoped migrations. It is a no-op when no migrations apply.
func RunWorkflow ¶
RunWorkflow executes a workflow function and renders progress via Bubble Tea with spinners and status icons, or raw zerolog output when --non-interactive is set. It returns the first error encountered (workflow execution error or step failure) so cobra RunE handlers can propagate it to the top-level error handler in main.go.
func RunWorkflowBuilder ¶
RunWorkflowBuilder is a convenience wrapper that builds an automa workflow and runs it via RunWorkflow.
func SkipGlobalChecks ¶
SkipGlobalChecks marks a command to skip global pre-run checks. This is useful for commands like 'install' that need to run before any checks can be performed. It sets the annotation "requireGlobalChecks" to "false".
Types ¶
type CommaSplitStringsFlagDefinition ¶
type CommaSplitStringsFlagDefinition struct {
Name string
ShortName string
Description string
Default []string
}
CommaSplitStringsFlagDefinition defines a []string flag whose values are comma-split at parse time: --items a,b,c yields []string{"a", "b", "c"}. Backed by pflag's StringSliceVarP / GetStringSlice. Use this when each value is a simple token with no embedded commas.
For values that themselves contain commas (e.g. a structured spec like "name=x,url=y"), use RepeatableStringFlagDefinition instead.
func (CommaSplitStringsFlagDefinition) Clone ¶
func (fp CommaSplitStringsFlagDefinition) Clone() CommaSplitStringsFlagDefinition
Clone returns an independent copy of the descriptor.
func (CommaSplitStringsFlagDefinition) MarkRequired ¶
func (fp CommaSplitStringsFlagDefinition) MarkRequired(cmd *cobra.Command, v bool) error
func (CommaSplitStringsFlagDefinition) MarkRequiredP ¶
func (fp CommaSplitStringsFlagDefinition) MarkRequiredP(cmd *cobra.Command, v bool) error
func (CommaSplitStringsFlagDefinition) SetVar ¶
func (fp CommaSplitStringsFlagDefinition) SetVar(cmd *cobra.Command, p *[]string, required bool)
func (CommaSplitStringsFlagDefinition) SetVarP ¶
func (fp CommaSplitStringsFlagDefinition) SetVarP(cmd *cobra.Command, p *[]string, required bool)
func (CommaSplitStringsFlagDefinition) SetVarPHidden ¶
func (fp CommaSplitStringsFlagDefinition) SetVarPHidden(cmd *cobra.Command, p *[]string, required bool)
func (CommaSplitStringsFlagDefinition) Value ¶
func (fp CommaSplitStringsFlagDefinition) Value(cmd *cobra.Command, args []string) ([]string, error)
Value mirrors FlagDefinition[T].Value: local → own persistent → inherited persistent.
func (CommaSplitStringsFlagDefinition) ValueLocal ¶
func (CommaSplitStringsFlagDefinition) ValueOwnPersistent ¶
type CountFlagDefinition ¶
CountFlagDefinition defines a count-style persistent flag (e.g. -V -V → 2). It is separate from FlagDefinition[int] because pflag registers count flags with type "count" and requires CountVarP/GetCount rather than IntVarP/GetInt.
func FlagVerbose ¶
func FlagVerbose() CountFlagDefinition
type FlagDefinition ¶
FlagDefinition defines a command-line flag typed by T.
func FlagAlloyClusterSecretStore ¶
func FlagAlloyClusterSecretStore() FlagDefinition[string]
func FlagApplicationStatePath ¶ added in v0.21.0
func FlagApplicationStatePath() FlagDefinition[string]
func FlagApplicationStateSize ¶ added in v0.21.0
func FlagApplicationStateSize() FlagDefinition[string]
func FlagArchivePath ¶
func FlagArchivePath() FlagDefinition[string]
func FlagArchiveSize ¶
func FlagArchiveSize() FlagDefinition[string]
func FlagBasePath ¶
func FlagBasePath() FlagDefinition[string]
func FlagChartRepo ¶
func FlagChartRepo() FlagDefinition[string]
func FlagClusterName ¶
func FlagClusterName() FlagDefinition[string]
func FlagConfig ¶
func FlagConfig() FlagDefinition[string]
func FlagContinueOnError ¶
func FlagContinueOnError() FlagDefinition[bool]
func FlagDaemonBNOrbit ¶ added in v0.20.0
func FlagDaemonBNOrbit() FlagDefinition[string]
FlagDaemonBNOrbit is the Kubernetes namespace (orbit) for the block-node component written into daemon.yaml. Required when daemon.yaml does not already exist and block-node is enabled.
func FlagDaemonBin ¶ added in v0.20.0
func FlagDaemonBin() FlagDefinition[string]
FlagDaemonBin is the optional path to a locally-built solo-provisioner-daemon binary. When omitted the binary is auto-downloaded from the official GitHub Releases URL embedded in the infrastructure catalog.
func FlagDaemonCNNodeID ¶ added in v0.20.0
func FlagDaemonCNNodeID() FlagDefinition[string]
FlagDaemonCNNodeID is the numeric node identifier written into daemon.yaml as the consensus-node node_id. Required when daemon.yaml does not already exist and consensus-node is enabled.
func FlagDaemonCNOrbit ¶ added in v0.20.0
func FlagDaemonCNOrbit() FlagDefinition[string]
FlagDaemonCNOrbit is the Kubernetes namespace (orbit) for the consensus-node component written into daemon.yaml. Required when daemon.yaml does not already exist and consensus-node is enabled.
func FlagDaemonCNUpgradeDir ¶ added in v0.20.0
func FlagDaemonCNUpgradeDir() FlagDefinition[string]
FlagDaemonCNUpgradeDir is an optional override for the consensus-node upgrade staging directory. Defaults to /opt/hgcapp/services-hedera/HapiApp2.0/data/upgrade/current.
func FlagDaemonChecksum ¶ added in v0.20.0
func FlagDaemonChecksum() FlagDefinition[string]
FlagDaemonChecksum is an optional sha256 hex digest used to verify a binary supplied via --daemon-bin. Ignored when --daemon-bin is not set (the catalog checksum is used for auto-downloaded binaries).
func FlagDaemonComponents ¶ added in v0.20.0
func FlagDaemonComponents() FlagDefinition[string]
FlagDaemonComponents selects which daemon components to enable. Accepts a comma-separated list of component names: "consensus-node", "block-node". When omitted the operator is prompted interactively.
func FlagDaemonFromConfig ¶ added in v0.20.0
func FlagDaemonFromConfig() FlagDefinition[string]
FlagDaemonFromConfig is an optional path to an existing daemon.yaml to copy into place before running the install workflow.
func FlagForce ¶
func FlagForce() FlagDefinition[bool]
func FlagHistoricRetention ¶
func FlagHistoricRetention() FlagDefinition[string]
func FlagLivePath ¶
func FlagLivePath() FlagDefinition[string]
func FlagLiveSize ¶
func FlagLiveSize() FlagDefinition[string]
func FlagLoadBalancerEnabled ¶
func FlagLoadBalancerEnabled() FlagDefinition[bool]
func FlagLogLevel ¶
func FlagLogLevel() FlagDefinition[string]
func FlagLogPath ¶
func FlagLogPath() FlagDefinition[string]
func FlagLogSize ¶
func FlagLogSize() FlagDefinition[string]
func FlagLokiURL ¶
func FlagLokiURL() FlagDefinition[string]
func FlagLokiUsername ¶
func FlagLokiUsername() FlagDefinition[string]
func FlagMetricsServer ¶
func FlagMetricsServer() FlagDefinition[bool]
func FlagMonitorBlockNode ¶
func FlagMonitorBlockNode() FlagDefinition[bool]
func FlagNamespace ¶
func FlagNamespace() FlagDefinition[string]
func FlagNoRestart ¶
func FlagNoRestart() FlagDefinition[bool]
func FlagNoReuseValues ¶
func FlagNoReuseValues() FlagDefinition[bool]
func FlagNodeType ¶
func FlagNodeType() FlagDefinition[string]
func FlagNonInteractive ¶
func FlagNonInteractive() FlagDefinition[bool]
func FlagOutputFormat ¶
func FlagOutputFormat() FlagDefinition[string]
func FlagPluginPreset ¶
func FlagPluginPreset() FlagDefinition[string]
func FlagPlugins ¶
func FlagPlugins() FlagDefinition[string]
func FlagPluginsPath ¶
func FlagPluginsPath() FlagDefinition[string]
func FlagPluginsSize ¶
func FlagPluginsSize() FlagDefinition[string]
func FlagProfile ¶
func FlagProfile() FlagDefinition[string]
func FlagPrometheusURL ¶
func FlagPrometheusURL() FlagDefinition[string]
func FlagPrometheusUsername ¶
func FlagPrometheusUsername() FlagDefinition[string]
func FlagPurgeStorage ¶ added in v0.18.0
func FlagPurgeStorage() FlagDefinition[bool]
func FlagRecentRetention ¶
func FlagRecentRetention() FlagDefinition[string]
func FlagReleaseName ¶
func FlagReleaseName() FlagDefinition[string]
func FlagRollbackOnError ¶
func FlagRollbackOnError() FlagDefinition[bool]
func FlagSkipHardwareChecks ¶
func FlagSkipHardwareChecks() FlagDefinition[bool]
FlagSkipHardwareChecks is a hidden persistent flag registered on the root command. When set, it skips CPU, memory, and storage validation in NewNodeSafetyCheckWorkflow (see internal/workflows/preflight.go). Privilege, user, and host profile checks still run. This flag is intentionally not supported by the "check" command since its purpose is to validate hardware requirements.
Used by: block node install, kube cluster install. Registered in: cmd/cli/commands/root.go (hidden). See docs/dev/hidden-flags.md for full documentation.
func FlagStopOnError ¶
func FlagStopOnError() FlagDefinition[bool]
func FlagTeleportValuesFile ¶
func FlagTeleportValuesFile() FlagDefinition[string]
func FlagTeleportVersion ¶
func FlagTeleportVersion() FlagDefinition[string]
func FlagValuesFile ¶
func FlagValuesFile() FlagDefinition[string]
func FlagVerificationPath ¶
func FlagVerificationPath() FlagDefinition[string]
func FlagVerificationSize ¶
func FlagVerificationSize() FlagDefinition[string]
func FlagVersion ¶
func FlagVersion() FlagDefinition[bool]
func FlagWithStorageReset ¶
func FlagWithStorageReset() FlagDefinition[bool]
func (FlagDefinition[T]) Clone ¶
func (fp FlagDefinition[T]) Clone() FlagDefinition[T]
Clone returns an independent copy of the descriptor. Useful when you need a local variant with a different default or description.
func (FlagDefinition[T]) MarkRequired ¶
func (fp FlagDefinition[T]) MarkRequired(cmd *cobra.Command, v bool) error
func (FlagDefinition[T]) MarkRequiredP ¶
func (fp FlagDefinition[T]) MarkRequiredP(cmd *cobra.Command, v bool) error
func (FlagDefinition[T]) SetVar ¶
func (fp FlagDefinition[T]) SetVar(cmd *cobra.Command, p *T, required bool)
SetVar sets up the non-persistent flag and exits on error.
func (FlagDefinition[T]) SetVarP ¶
func (fp FlagDefinition[T]) SetVarP(cmd *cobra.Command, p *T, required bool)
SetVarP sets up the persistent flag and exits on error.
func (FlagDefinition[T]) SetVarPHidden ¶
func (fp FlagDefinition[T]) SetVarPHidden(cmd *cobra.Command, p *T, required bool)
SetVarPHidden registers the flag as a persistent flag and marks it hidden so it does not appear in --help. Useful for deprecated or internal-only flags that must still be accepted on the command line.
func (FlagDefinition[T]) Value ¶
func (fp FlagDefinition[T]) Value(cmd *cobra.Command, args []string) (T, error)
Value resolves a flag value using the following precedence:
- Local (non-persistent) flags on this command
- Own persistent flags on this command (defined via SetVarP on this command directly)
- Persistent flags inherited from parent/root commands (merged by Cobra via ParseFlags)
Use ValueLocal() or ValueOwnPersistent() if you need strict single-scope semantics.
func (FlagDefinition[T]) ValueLocal ¶
func (fp FlagDefinition[T]) ValueLocal(cmd *cobra.Command, args []string) (T, error)
func (FlagDefinition[T]) ValueOwnPersistent ¶
func (fp FlagDefinition[T]) ValueOwnPersistent(cmd *cobra.Command, args []string) (T, error)
ValueOwnPersistent reads the value of a persistent flag defined directly on this command (via SetVarP). It does NOT search ancestor/parent commands.
Use Value() if you want the full resolution chain (local → own persistent → inherited persistent). Use ValueLocal() if you want only local (non-persistent) flags on this command.
type RepeatableStringFlagDefinition ¶
type RepeatableStringFlagDefinition struct {
Name string
ShortName string
Description string
Default []string
}
RepeatableStringFlagDefinition defines a []string flag whose values are collected from repeated --flag occurrences without comma-splitting: each --item v contributes one element verbatim, so values that themselves contain commas (e.g. structured specs like "name=x,url=y") are preserved. Backed by pflag's StringArrayVarP / GetStringArray.
func FlagLokiRemotes ¶
func FlagLokiRemotes() RepeatableStringFlagDefinition
func FlagPrometheusRemotes ¶
func FlagPrometheusRemotes() RepeatableStringFlagDefinition
func (RepeatableStringFlagDefinition) Clone ¶
func (fp RepeatableStringFlagDefinition) Clone() RepeatableStringFlagDefinition
Clone returns an independent copy of the descriptor.
func (RepeatableStringFlagDefinition) MarkRequired ¶
func (fp RepeatableStringFlagDefinition) MarkRequired(cmd *cobra.Command, v bool) error
func (RepeatableStringFlagDefinition) MarkRequiredP ¶
func (fp RepeatableStringFlagDefinition) MarkRequiredP(cmd *cobra.Command, v bool) error
func (RepeatableStringFlagDefinition) SetVar ¶
func (fp RepeatableStringFlagDefinition) SetVar(cmd *cobra.Command, p *[]string, required bool)
func (RepeatableStringFlagDefinition) SetVarP ¶
func (fp RepeatableStringFlagDefinition) SetVarP(cmd *cobra.Command, p *[]string, required bool)
func (RepeatableStringFlagDefinition) SetVarPHidden ¶
func (fp RepeatableStringFlagDefinition) SetVarPHidden(cmd *cobra.Command, p *[]string, required bool)
func (RepeatableStringFlagDefinition) Value ¶
Value mirrors FlagDefinition[T].Value: local → own persistent → inherited persistent.
func (RepeatableStringFlagDefinition) ValueLocal ¶
func (RepeatableStringFlagDefinition) ValueOwnPersistent ¶
type RootFlags ¶
RootFlags contains the flags registered on the root command and available to every subcommand via persistent inheritance.
type SetupResult ¶
type SetupResult struct {
Config models.Config
StateManager state.Manager
RealityChecker reality.Checkers
Runtime *rsl.RuntimeResolver
}
func Setup ¶
func Setup() (*SetupResult, error)
Setup performs the common setup steps for all commands. It includes loading configuration, initializing the state manager, reality checker and runtime resolver