Sfoglia il codice sorgente

ci: use PAT & trigger only if os is windows (#479)

Co-authored-by: Ayyan <ayn2op@gmail.com>
vvxrtues 1 anno fa
parent
commit
0361434c4c
1 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. 3 3
      .github/workflows/ci.yml

+ 3 - 3
.github/workflows/ci.yml

@@ -28,12 +28,12 @@ jobs:
             discordo.exe
 
       - name: Send repository dispatch
-        if: ${{ github.event_name == 'push' && github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
+        if: ${{ runner.os == 'Windows' && github.event_name == 'push' && github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
         env:
-          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          GH_TOKEN: ${{ secrets.PAT }}
         run: |
           gh api \
             --method POST \
             -H "Accept: application/vnd.github+json" \
             /repos/vvirtues/bucket/dispatches \
-            -f "event_type=discordo-ci-completed"
+            -f "event_type=discordo-ci-completed"