Skip to content

Release Configuration ​

Reference of the release options - the steps of relizy release (changelog, publish, commit, tag, push, provider release, social posts, PR comment) and the report of the release (GitHub Actions outputs, JSON, dotenv, markdown). For the order of the steps, see relizy release.

ts
import { defineConfig } from 'relizy'

export default defineConfig({
  release: {
    social: false,
    report: { dotenv: 'relizy.env' },
  },
})

Steps ​

Each option is a boolean, and a CLI flag disables it for a run (--no-verify turns noVerify on).

OptionDefaultCLIEffect
changelogtrue--no-changelogWrite the CHANGELOG.md files
publishtrue--no-publishPublish the packages to the registry, see Publish
committrue--no-commitCommit the release files and create the tags (templates.commitMessage, see Templates). Without it, nothing is pushed
gitTagtrue--no-git-tagCreate the release tags; without it, the commit is pushed without --follow-tags
noVerifyfalse--no-verifyCommit with --no-verify, skipping the git hooks
pushtrue--no-pushPush the commit and the tags. Requires commit
synctrue--no-syncMerge the released branch into the branches of the rules of sync that match it once the release commit is pushed (nothing without a matching rule). Requires push, see Branch Sync
providerReleasetrue--no-provider-releaseCreate the GitHub or GitLab releases. A version group can override it
socialtrue--no-socialPost the release on the platforms enabled in social (social.twitter.enabled, social.slack.enabled), see Social. A version group can override it
prCommenttrue--no-pr-commentComment the pull request with the outcome of the release, see PR Comment
cleantrue--no-cleanWith bump.clean, fail on uncommitted changes; otherwise keep them, with a confirmation when they touch the files the release commits

--canary (or canary) turns off changelog, commit, gitTag, push, providerRelease, social and sync, whatever the config: see Canary Releases.

canary ​

  • Type: boolean
  • Default: false
  • CLI: --canary

Release a canary version of the current commit instead of a release, as relizy release --canary: {nextVersion}-0.{preid}-{sha}, published with the canary dist-tag (--tag, or publish.tag of a canary profile, one that sets release.canary), without changelog, commit, git tag, push, provider release, social post nor branch sync. Set it in a profile (profiles: { canary: { release: { canary: true } } }) to make relizy release --profile canary a canary release. See Canary Releases.

report ​

  • Type: { github?: boolean, json?: string, dotenv?: string, markdown?: string }
  • Default: { github: true }
  • CLI: --report-json <file>, --report-dotenv <file>, --report-markdown <file>

Report of the release, to run something only when a release happens (see CI/CD). Written after a release, when there is nothing to release and when the release fails (not for a refused or cancelled prompt), in dry-run too. The paths are relative to cwd.

KeyEffect
githubOn GitHub Actions, write the outputs below to the step, plus report (the report as JSON) and summary (markdown), and the summary to the run
jsonWrite the whole report (the value returned by release()) to this JSON file
dotenvWrite the outputs to this file as RELIZY_<OUTPUT>=value (RELIZY_RELEASED=true), for the artifacts:reports:dotenv of GitLab CI. Without install: no value has a space, the file can be sourced (. ./relizy.env)
markdownWrite the summary of the release to this markdown file, e.g. for an artifact of GitLab CI
OutputValue
releasedtrue when the release happened, never in dry-run
statusreleased, nothing or failed
versionThe repository version (standalone, unified or selective; with monorepo.groups, the first unified/selective group released), empty otherwise
tagsThe created tags, comma-separated
packagesThe released packages, comma-separated name@version
branchThe branch of the release
commitThe short hash of the release commit
dist_tagsThe dist-tags of the published versions, comma-separated (publish.tag, not the tag of the registries)
urlsWhat the release created (npm pages, provider releases, tweet, pull request), comma-separated
installThe command installing the published versions (up to 3 packages), not in the dotenv file
synced_branchesThe branches of the sync that have the release, or its pull request, after the sync, comma-separated
failed_stepsThe steps that failed without stopping the release (social, providerRelease, sync, prComment), comma-separated, empty when none failed
group_<name>_versionThe version of a unified/selective group of monorepo.groups released (group_ecosystem_version)
package_<name>_versionThe new version of a released package (@acme/ui-kit gives package_acme_ui_kit_version)

The group_* and package_* outputs are only set when the release happened (not in dry-run): a group or a package not released has none.

The JSON report has the same content, with the packages by version group: see ReleaseReport.

yaml
# GitHub Actions
- id: release
  uses: relizy/action@v2
- if: steps.release.outputs.released == 'true'
  run: echo "Released ${{ steps.release.outputs.tags }}"

The summary is the end of the output of relizy release, the summary of the GitHub Actions run, the PR comment and the markdown file: the versions, what the release contains (features, fixes, breaking changes, contributors), what each step did with the links of what it created, the AI rewrites (tokens and cost), the install command and the packages.