diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index ab32318..fbe02a9 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -4,6 +4,11 @@ on: push: tags: - "v*" + workflow_dispatch: + inputs: + tag: + description: "Tag to publish (e.g. v0.1.4)" + required: true jobs: # ── 1. Run tests before publishing ───────────────────────────────────────── @@ -12,6 +17,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + ref: ${{ github.event.inputs.tag || github.ref }} - uses: actions/setup-python@v5 with: python-version: "3.11" @@ -26,6 +33,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + ref: ${{ github.event.inputs.tag || github.ref }} - uses: actions/setup-python@v5 with: @@ -84,5 +93,6 @@ jobs: - name: Create GitHub Release uses: softprops/action-gh-release@v2 with: + tag_name: ${{ github.event.inputs.tag || github.ref_name }} files: dist/* generate_release_notes: true