Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
arrow-up

GitHub Action

bump-everywhere

1.0.1

bump-everywhere

arrow-up

bump-everywhere

Bump git tag to the next version, generate a changelog file, and create a release with auto-generated release notes

Installation

Copy and paste the following snippet into your .yml file.

              

- name: bump-everywhere

uses: undergroundwires/[email protected]

Learn more about this action in undergroundwires/bump-everywhere

Choose a version

bump-everywhere

🚀 Automate versioning, changelog creation, README updates and GitHub releases using GitHub Actions,npm, docker or bash.

contributions welcome Quality checks Bump & release Publish Test Code size Docker image size Auto-versioned by bump-everywhere

functions of bump-everywhere

Features

Allows you to automatically:

  • Bump your sematic git tag by increasing the patch version
  • Create & commit a changelog file
  • If npm project then bump package.json version and commit
  • Check README.md file, if it has references to older version, update with never version.
  • Create a release on GitHub with auto-generated release notes

It supports safe re-runs, it means that if you can run it for an already bumped or tagged repository, it'll not increase the version as everything is still up-to-date. It protects against recursive runs.

Usage

Option 1. Use GitHub actions

- uses: undergroundwires/bump-everywhere@master
  with:
    # Repository name with owner to bump & release. For example, undergroundwires/bump-everywhere
    # (Optional) Default: ${{ github.repository  }}
    repository: ''

    # Name of the user who'll commit the changelog
    # (Optional) Default: ${{ github.actor }}
    user: ''

    # Personal access token (PAT) used to clone & push to the repository.
    # If you use default, it'll not trigger other actions, but your own PAT then it triggers new actions
    # (Optional) Default: ${{ github.token }}
    git-token: ''

    # Personal access token (PAT) used to release to GitHub.
    # If you use default, it'll not trigger other actions, but your own PAT then it triggers new actions
    # (Optional) Default: ${{ github.token }}
    release-token: ''

Option 2. Use npm

With installation:

npm install -g bump-everywhere # or "npm install bump-everywhere --save-dev" for local installations
bump-everywhere --repository "undergroundwires/privacy.sexy" --user "bot-commiter-name" --git-token "PAT_TOKEN" --release-token "PAT_TOKEN"

Or without installation:

npx bump-everywhere --repository "undergroundwires/privacy.sexy" --user "bot-commiter-name" --git-token "PAT_TOKEN" --release-token "PAT_TOKEN"

Option 3. Use Docker

  • To get the image you can either:
    • Pull from docker hub using docker pull undergroundwires/bump-everywhere:latest
    • Or build image yourself using docker build . --tag undergroundwires/bump-everywhere:latest
  • Run with arguments: docker run undergroundwires/bump-everywhere "undergroundwires/privacy.sexy" "bot-user" "GitHub PAT for pushes" "GitHub PAT for releases"
    • Parameter order: repository, user, git push token, GitHub release token

Option 4. Use scripts

  1. Ensure bash, git, curl, jq exists in your environment
    • run e.g. apk add bash git curl jq
  2. Clone this repository: git clone https://github.com/undergroundwires/bump-everywhere
    • or optionally add this repository as git submodule: git submodule add https://github.com/undergroundwires/bump-everywhere
  3. Call the script as following :
bash "scripts/bump-everywhere.sh" \
    --repository "undergroundwires/privacy.sexy" \
    --user "bot-commiter-name" \
    --git-token "PAT_TOKEN" \
    --release-token "PAT_TOKEN"

Updating minor & major versions

  • You manually tag your last commit to update major & minor versions.
  • E.g.
    • git commit -m "bumped version to 1.2.0" --allow-empty
    • git tag 1.2.0
    • git push && git push --tags

All scripts

You can also use following scripts individually (check script files for usage, prerequisites & dependencies):

Some example usages

privacy.sexy | safe-email | ez-consent | aws-static-site-with-cd

GitOps

CI/CD is fully automated for this repo using different GIT events & GitHub actions.

GitOps flow

Support

  • Feel free to use the badge in the README.md of repository where you use bump-everywhere:
    • (it'll look like: Auto-versioned by bump-everywhere)
[![Auto-versioned by bump-everywhere](https://github.com/undergroundwires/bump-everywhere/blob/master/badge.svg?raw=true)](https://github.com/undergroundwires/bump-everywhere)