Skip to content

Configuration

All semrel behaviour is controlled by a single YAML file, .semrel.yaml, in the root of your repository. You can specify a different path with --config.

version: 1
branches:
- name: main
- name: next
prerelease: true
- name: "release/+([0-9])+([0-9]).x"
release:
rules:
- type: feat
bump: minor
- type: fix
bump: patch
- type: perf
bump: patch
- type: revert
bump: patch
# Breaking changes are always a major bump regardless of type.
# Triggered by a "BREAKING CHANGE:" footer or a "!" suffix (feat!:).
plugins:
- name: github
args:
owner: MyOrg
repo: my-repo
- name: conventional-commits
- name: slack-notify
path: ./.semrel/slack-notify # path to a local plugin binary
args:
webhook_url: "https://hooks.slack.com/..."

The config schema version. Always set to 1 for now.

A list of branches from which releases can be made.

FieldTypeDefaultDescription
namestringBranch name or glob pattern
prereleaseboolfalseWhen true, releases from this branch get a pre-release suffix (e.g. v1.2.0-next.1)

Only commits landing on a listed branch trigger a release. All other branches are ignored.

Maps commit types (from the Conventional Commits type: prefix) to a SemVer bump level.

FieldValuesDescription
typeany stringThe Conventional Commit type (e.g. feat, fix, perf)
bumpmajor | minor | patchThe version component to increment

An ordered list of plugins to load for the release pipeline.

FieldTypeRequiredDescription
namestringyesPlugin identifier
pathstringnoPath to a local plugin binary. If omitted, semrel looks in .semrel/<name>
argsmapnoArbitrary key-value pairs passed to every plugin RPC as ReleaseContext.config

Plugins are started as child processes and communicate with semrel over a local gRPC connection. See the Plugin Overview for the full plugin type catalogue.