From 288cf459ceb4cae9058003d5a694dba09b81ba8e Mon Sep 17 00:00:00 2001 From: Chamlai <31847168+VeiveHata@users.noreply.github.com> Date: Tue, 24 Sep 2024 16:07:49 +0200 Subject: [PATCH] GA on push: update package version (#8) * Create push.yml * THC-444: update readme --------- Co-authored-by: Volha Chamlai --- .github/workflows/push.yml | 21 +++++++++++++++++++++ README.md | 18 ++++++++++++++++++ 2 files changed, 39 insertions(+) create mode 100644 .github/workflows/push.yml diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml new file mode 100644 index 0000000..4452e09 --- /dev/null +++ b/.github/workflows/push.yml @@ -0,0 +1,21 @@ +name: Package version bump +on: + push: + branches: + - main + +jobs: + bump: + name: Version bump + runs-on: ubuntu-latest + steps: + + - name: Check out Git repository + uses: actions/checkout@v4 + + - name: Bump the version + uses: jpb06/bump-package@latest + with: + major-keywords: M,MAJOR,major + minor-keywords: m,minor + patch-keywords: fix,patch diff --git a/README.md b/README.md index 2b0f5fc..4ff19f6 100644 --- a/README.md +++ b/README.md @@ -63,6 +63,24 @@ $ pnpm install Once you installed depedencies you are good to start development, no other action is required. + +## Version update + +Package version update is done automatically according to commit message. Check it here: [Bump package version](https://github.com/marketplace/actions/bump-package-version). + +- there is no default version bump, be sure to provide correct commit message in case you want to update the version +- check different options for providing commit message for different [merge strategies](https://github.com/marketplace/actions/bump-package-version#-pull-requests) + + +For automatic version bump start you commit message with: + +**MAJOR** - `M:`,` MAJOR:`, `major:` + +**MINOR** - `m:`, `minor:` + +**PATCH** - `fix:`, `patch:` + + ## Publication To publish next version of this npm package first create a branch from `main`. Release branch should be named: `release-[versionTag]`, where `[versionTag]` is tag of version you want to publish.