Documentation
¶
Overview ¶
Package enable is the gtb-only `enable` command. It turns on a capability of a generated tool and rewrites the existing generated wiring to match, as opposed to `generate`, which adds new user-facing surface (commands, flags, config fields).
Simple on/off built-in features (ai, config, telemetry, init, update, mcp, docs, doctor, changelog) are a positional argument on `enable` itself — `gtb enable ai` flips properties.features in .gtb/manifest.yaml and re-renders the root command. Capabilities with their own configuration are scoped subcommands: `gtb enable signing` turns on consumer-side release-signing verification with its own flag set. cobra routes a first argument that matches a subcommand (signing) there, and otherwise falls through to the parent's positional feature handler.
This package lives under internal/cmd/ because the commands belong to the framework author, not the framework's downstream consumers. See docs/development/specs/2026-06-16-enable-disable-features.md and docs/development/specs/2026-06-10-signing-generator-feature.md.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrInvalidBackend = errors.New("invalid --backend: not a registered signing backend")
ErrInvalidBackend is returned when --backend is not a registered signing backend.
var ErrInvalidKeySource = errors.New("invalid --key-source: must be embedded, external, or both")
ErrInvalidKeySource is returned when --key-source is not one of the accepted values.
Functions ¶
func NewCmdEnable ¶
NewCmdEnable returns the top-level `gtb enable [feature]` command. A built-in feature passed positionally is toggled on; a first argument matching a scoped subcommand (signing) routes there instead; no argument opens the feature picker.
Types ¶
This section is empty.