From 37577ed0fc4fc513cadc617719e9b055423e2549 Mon Sep 17 00:00:00 2001 From: Riki Nakamura Date: Mon, 24 Feb 2025 09:40:58 +0900 Subject: [PATCH 1/4] Update example --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index d2bb110..9d34acb 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,9 @@ jobs: steps: - uses: conjikidow/bump-version@v1 with: + label-major: "major update" + label-minor: "minor update" + label-patch: "patch update" labels-to-add: "automated,version-bump" ``` From ca6b23b83798343f0e709d9cd4fce572dc4826b8 Mon Sep 17 00:00:00 2001 From: Riki Nakamura Date: Mon, 24 Feb 2025 09:57:58 +0900 Subject: [PATCH 2/4] Add instructions --- README.md | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 9d34acb..c783f20 100644 --- a/README.md +++ b/README.md @@ -14,15 +14,21 @@ Once the version bump PR is merged, it automatically creates a new tag for the b ### Workflow Example -Add the following workflow to your repository to automatically bump the version when a PR is merged. Save it as `.github/workflows/bump-version.yaml`, for example. +Below is an example workflow you can add to your repository to automatically bump the version when a pull request is merged. +You can save it in a file such as `.github/workflows/bump-version.yaml`. + +Make sure your workflow includes the following: + +- The `on: pull_request: types: [closed]` trigger to run the workflow whenever a pull request is closed. +- The condition `if: github.event.pull_request.merged == true` to ensure the workflow only proceeds if the pull request was merged. +- The permissions under `permissions:` to allow the workflow to update repository contents and pull requests. ```yaml name: "Bump Version" on: pull_request: - types: - - closed + types: [closed] jobs: bump-version: From 26204f701100b114444fc946eb18bc16b8f4c7c6 Mon Sep 17 00:00:00 2001 From: Riki Nakamura Date: Mon, 24 Feb 2025 10:07:37 +0900 Subject: [PATCH 3/4] Add note about labels-to-add --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index c783f20..9533e8e 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,8 @@ jobs: | `label-patch` | The label used to trigger a patch version bump | No | `"update::patch"` | | `labels-to-add` | The labels to add to the PR for version bumping | No | None | +> **Note:** Any labels specified in `labels-to-add` must already exist in your repository. If they do not, create them in advance to avoid errors. + ### bump-my-version Configuration To use this action, ensure that your project is configured to work with `bump-my-version`. From 11d6b549e11a92e072591568b6eb7171252d9236 Mon Sep 17 00:00:00 2001 From: Riki Nakamura Date: Mon, 24 Feb 2025 10:13:05 +0900 Subject: [PATCH 4/4] Add contribution section to README --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 9533e8e..92090e7 100644 --- a/README.md +++ b/README.md @@ -137,3 +137,8 @@ In addition to the full version tag (`vX.Y.Z`), this action updates existing maj - `v1.2.3 → v1.2.4`: Update `v1.2` and `v1` if they exist. - `v1.2.3 → v1.3.0`: Create `v1.3` if `v1.2` exists, update `v1` if it exists. - `v1.2.3 → v2.0.0`: Create `v2.0` if `v1.2` exists, create `v2` if `v1` exists. + +## Contributing & Feedback + +Contributions, bug reports, and feedback are always welcome! +Thank you for helping improve this project for everyone!