From ba8924fb706b09dbf5a8c41b4850c115e3164a00 Mon Sep 17 00:00:00 2001 From: qwyng Date: Sun, 24 Sep 2023 00:34:04 +0900 Subject: [PATCH] Gem is now published while automatically bumping the version. --- ....yml => bump_version_and_push_to_rubygems.yml} | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) rename .github/workflows/{publish_to_rubygems.yml => bump_version_and_push_to_rubygems.yml} (66%) diff --git a/.github/workflows/publish_to_rubygems.yml b/.github/workflows/bump_version_and_push_to_rubygems.yml similarity index 66% rename from .github/workflows/publish_to_rubygems.yml rename to .github/workflows/bump_version_and_push_to_rubygems.yml index affe7de..4cd20c3 100644 --- a/.github/workflows/publish_to_rubygems.yml +++ b/.github/workflows/bump_version_and_push_to_rubygems.yml @@ -1,7 +1,15 @@ -name: Publish to RubyGems +name: Bump version and Push to RubyGems on: workflow_dispatch: + inputs: + miner-or-major: + description: 'Minor or major release' + required: true + default: 'minor' + options: + - 'minor' + - 'major' jobs: build: @@ -17,7 +25,12 @@ jobs: uses: ruby/setup-ruby@v1 with: ruby-version: 3.2 + - run: bundle install + - run: gem install gem-release + + - name: Bump version + run: gem bump --version ${{ github.event.inputs.miner-or-major }} - name: Publish to RubyGems run: |