From be3d57ae182a281f806aefba66d2ba499b343fcf Mon Sep 17 00:00:00 2001 From: baobach <95854748+baobach@users.noreply.github.com> Date: Wed, 9 Oct 2024 19:18:11 +0700 Subject: [PATCH] ci: update the build flow trigger when received tag push --- .github/workflows/main.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 48d237f..fe29520 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -41,9 +41,8 @@ jobs: # Only run this job if the "ci" job passes needs: test - # Only run this job if new work is pushed to "main" - if: github.event_name == 'push' && github.ref == 'refs/heads/main' - + # Only run on pushes to tags + if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') # only publish to PyPI on tag pushes name: Build distribution 📦 runs-on: ubuntu-latest