Summary
Add a semrel config subcommand that walks the user through creating or updating .semrel.yaml interactively, with contextual help, validation and schema-aware completion.
Motivation
Getting a correct .semrel.yaml on the first try is non-trivial: users have to know the right plugin names, available args, branch patterns, and phase values. A guided wizard lowers the barrier significantly for new adopters and reduces config mistakes.
Proposed UX
Initial setup
$ semrel config init
? Repository forge [GitHub / GitLab / Gitea / Bitbucket / bare-git]
> GitHub
? Release branch(es) [main]
> main
? Add a commit analyzer plugin? [analyzer-conventional / analyzer-default / skip]
> analyzer-conventional
? Commit types triggering a minor bump [feat]
> feat
? Commit types triggering a patch bump [fix,perf,refactor]
> fix,perf,refactor
? Add a changelog generator? [changelog-md / changelog-html / release-notes / skip]
> changelog-md
? Add notification hooks? [slack / teams / matrix / email / jira / skip]
> slack
? Slack webhook URL []
> https://hooks.slack.com/services/…
✔ .semrel.yaml written!
Update existing config
$ semrel config add-plugin
$ semrel config set branches.0.name feature/*
$ semrel config validate
Subcommands
| Subcommand |
Description |
semrel config init |
Full wizard to create .semrel.yaml from scratch |
semrel config add-plugin |
Interactively append a plugin block |
semrel config validate |
Validate the current config against the JSON Schema |
semrel config set <key> <value> |
Set a single top-level or nested key |
semrel config show |
Print the resolved config (after defaults are applied) |
Implementation notes
- Prompt library:
github.com/charmbracelet/huh or similar terminal-form library
- The wizard fetches available plugins from the semrel registry (
/plugins.json) to offer auto-complete — works offline with a built-in fallback list
- Generated YAML includes comments explaining each field
--no-interactive flag for CI (validates and exits)
Acceptance criteria
Summary
Add a
semrel configsubcommand that walks the user through creating or updating.semrel.yamlinteractively, with contextual help, validation and schema-aware completion.Motivation
Getting a correct
.semrel.yamlon the first try is non-trivial: users have to know the right plugin names, availableargs, branch patterns, and phase values. A guided wizard lowers the barrier significantly for new adopters and reduces config mistakes.Proposed UX
Initial setup
Update existing config
Subcommands
semrel config init.semrel.yamlfrom scratchsemrel config add-pluginsemrel config validatesemrel config set <key> <value>semrel config showImplementation notes
github.com/charmbracelet/huhor similar terminal-form library/plugins.json) to offer auto-complete — works offline with a built-in fallback list--no-interactiveflag for CI (validates and exits)Acceptance criteria
semrel config initwizard generates a valid.semrel.yamlsemrel config validateexits 0/non-zero with actionable errorssemrel config validatewithout errorsvalidatesubcommand with valid and invalid configs