From cef984a93e1a29d10f26066efbd869674c249194 Mon Sep 17 00:00:00 2001 From: Illia Antypenko Date: Fri, 17 Oct 2025 22:12:15 +0200 Subject: [PATCH] Add ability to select publish type --- .github/workflows/publish.yml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 20c21ff..973d92b 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,7 +1,18 @@ name: Publish to npm on: - workflow_dispatch: ~ + workflow_dispatch: + inputs: + bump: + description: 'Version bump type' + required: true + default: 'minor' + type: choice + options: + - patch + - minor + - major + push: branches: - main @@ -40,7 +51,7 @@ jobs: run: | git config --global user.name "github-actions[bot]" git config --global user.email "github-actions[bot]@users.noreply.github.com" - TAG=$(npm version minor -m "Release %s [skip ci]") + TAG=$(npm version ${{ github.event.inputs.bump || 'minor' }} -m "Release %s [skip ci]") echo "Created tag: $TAG" echo "tag=$TAG" >> "$GITHUB_OUTPUT" git push origin main --follow-tags