Skip to content

bump ​

Compute the new versions from the commits and write them to the package.json files, without changelog, commit, tag nor publication.

Usage ​

bash
relizy bump [options]

bump is the first step of release. It:

  1. checks the working directory is clean (unless --no-clean);
  2. computes the version of each package from its commits (see SemVer Convention), and its dependents (see Dependency Management);
  3. asks to confirm the new versions, unless --yes;
  4. writes them to the package.json files.

It exits with code 0 when no commit triggers a bump. The global options apply too (--dry-run, --group...).

Options ​

FlagDescriptionConfig
--major, --minor, --patchForce the bump type, instead of the one computed from the commitsbump.type
--prerelease, --premajor, --preminor, --prepatchBump to a prerelease version, see Prerelease Versionsbump.type
--preid <id>Prerelease identifier: alpha, beta, rc...bump.preid
--suffix <suffix>With a prerelease type, replace the last number: 1.0.0-beta.0 becomes 1.0.0-beta.<suffix>bump.suffix
--canaryWrite a canary version, {nextVersion}-0.canary-{sha} (bump.preid or --preid replaces canary), from the commits: the type flags, --force and --suffix are ignored, and the version stays in the package.json files. See Canary Releasesrelease.canary
--forceBump the packages even without a commit triggering a bump-
--no-cleanBump with uncommitted changes. In a terminal, asks to confirm when they touch a file the release commitsbump.clean
--yesConfirm the new versions without asking. Required without an interactive terminal (CI)bump.yes
--private-packages <mode>release: bump the private packages too, ignore: leave them outmonorepo.privatePackages

Examples ​

bash
# Preview the new versions
relizy bump --dry-run

# Computed from the commits, without confirmation
relizy bump --yes

# Force a minor
relizy bump --minor

# 1.2.0 -> 1.3.0-beta.0, then 1.3.0-beta.1
relizy bump --preminor --preid beta
relizy bump --prerelease --preid beta

# 1.3.0-beta.0 -> 1.3.0-beta.<short sha>
relizy bump --prerelease --preid beta --suffix "$(git rev-parse --short HEAD)"

# 1.2.3 -> 1.3.0-0.canary-a3f4b2c
relizy bump --canary

See Also ​