Kaynağa Gözat

Updaet main.yml

Alex Gheorghita 3 yıl önce
ebeveyn
işleme
7ac9dce59f
1 değiştirilmiş dosya ile 2 ekleme ve 3 silme
  1. 2 3
      .github/workflows/main.yml

+ 2 - 3
.github/workflows/main.yml

@@ -1,14 +1,14 @@
 name: Publish to PyPI
 
 on:
-    push:
-        branches: [master]
+    create:
 
     # Allows you to run this workflow manually from the Actions tab
     workflow_dispatch:
 
 jobs:
     build:
+        if: ${{ startsWith(github.ref, 'refs/tags') }}
         runs-on: ubuntu-latest
         steps:
             - name: Prepare repo
@@ -40,7 +40,6 @@ jobs:
             #           repository_url: https://test.pypi.org/legacy/
 
             - name: Publish distribution 📦 to PyPI
-              if: ${{ startsWith(github.ref, 'refs/tags') }}
               uses: pypa/gh-action-pypi-publish@master
               with:
                   password: ${{ secrets.PIP_API_TOKEN }}