📦 ci: add pypi environment to publish workflows
swadhinbiswas committed 3 months ago
4ebffa2
1 parent 2d5971d
commit 4ebffa2
2 files changed
+8 -4
Showing 2 changed files+8-4
▼.github/workflows/publish.yml
+3-2
| @@ -86,6 +86,7 @@ jobs: | ||
86 | 86 | name: Publish to PyPI |
87 | 87 | runs-on: ubuntu-latest |
88 | 88 | needs: build-wheels |
89 | + environment: pypi | |
89 | 90 | permissions: |
90 | 91 | id-token: write |
91 | 92 | steps: |
| @@ -94,8 +95,8 @@ jobs: | ||
94 | 95 | pattern: wheels-* |
95 | 96 | merge-multiple: true |
96 | 97 | path: dist |
97 | - - name: Publish | |
98 | - uses: pypa/gh-action-pypa-publish@release/v1 | |
98 | + - uses: pypa/gh-action-pypa-publish@release/v1 | |
99 | 99 | with: |
100 | 100 | packages-dir: dist/ |
101 | 101 | skip-existing: true |
102 | + verbose: true | |
102 | 103 | |
▼.github/workflows/wheels.yml
+5-2
| @@ -101,6 +101,7 @@ jobs: | ||
101 | 101 | runs-on: ubuntu-latest |
102 | 102 | needs: build-wheels |
103 | 103 | if: startsWith(github.ref, 'refs/tags/v') |
104 | + environment: pypi | |
104 | 105 | permissions: |
105 | 106 | id-token: write |
106 | 107 | steps: |
| @@ -109,5 +110,7 @@ jobs: | ||
109 | 110 | pattern: wheels-* |
110 | 111 | merge-multiple: true |
111 | 112 | path: dist |
112 | - - name: Publish to PyPI | |
113 | - uses: pypa/gh-action-pypa-publish@release/v1 | |
113 | + - uses: pypa/gh-action-pypa-publish@release/v1 | |
114 | + with: | |
115 | + skip-existing: true | |
116 | + verbose: true | |
114 | 117 | |