From ffcb8ec14029b316c4738e470d377a985d5357cf Mon Sep 17 00:00:00 2001 From: yeongpin Date: Sat, 8 Feb 2025 22:00:19 +0800 Subject: [PATCH] update --- .github/workflows/build.yml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f48104e..c5260f0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,6 +1,12 @@ name: Build Release on: + workflow_dispatch: + inputs: + version: + description: 'Version number (without v prefix)' + required: true + default: '1.0.0' push: tags: - 'v*' @@ -31,10 +37,15 @@ jobs: with: python-version: '3.10' - - name: Get version from tag + - name: Get version id: get_version shell: bash - run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV + run: | + if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then + echo "VERSION=${{ github.event.inputs.version }}" >> $GITHUB_ENV + else + echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV + fi - name: Make scripts executable (Unix) if: runner.os != 'Windows'