Skip to content

TomerFi/version-bumper-action

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

Version Bumper Action

📦🚀 Spice up your release workflows with automated version bumps! 🚀📦

About

The Version Bumper Action uses the version bumper tool to figure out the next semantic version bump based on conventional commits, or plain instructions.

Upgrading from version 1 to 2? Click here.

Successful upgrades examples: alexa-skills-tester, github-viewer-stats, auto-me-bot, tomfi-archetypes, shabbat-api,

Version 3 introduced breaking changes

  • The action was rebuilt using Node.js.
  • Changes in the action flags:
    • changelog was removed.
    • preset was removed.
    • folder was changed to path. It's worth mentioning the folder/path requires a full path and not a folder relative to the workspace. (folder will eventually be removed).
    • bumpoverride was changed to bump (bumpoverride will eventually be removed).

Usage example

- uses: actions/checkout@v2
  with:
    # fetch-depth 0 will check out all the commits and tags needed for the bumper
    fetch-depth: 0

- id: bumper
  uses: tomerfi/version-bumper-action@2.0.1

# assuming previous tag was 1.2.4 and feat-type commits were made, this will print 1.3.0.
- run: echo ${{ steps.bumper.outputs.next }}

Inputs

Key Description Default value
source Source for the bump, any semver string or 'git' to fetch from tags git
bump Target bump, 'major', 'minor', 'patch', 'auto'. An 'auto' bump only works with a 'git' source auto
label Development iteration build label -dev
path When source is 'git', set repository path ${{ github.workspace }}

Outputs

Key Description Example
current The original version 1.2.3
bump The bump performed patch
next The next version 1.2.4
dev The next development iteration version 1.2.5-dev
major_part The major part of the next version 1
minor_part The minor part of the next version 2
patch_part The patch part of the next version 4
dev_patch_part The patch part of the development iteration 5-dev
bump_object The original object returned from the version bumper tool

Contributors all-contributors-badge

Jasper Vaneessen
Jasper Vaneessen

💻 📖
Lucas Schmutzler
Lucas Schmutzler

💻
mrdoodles
mrdoodles

💻 📖