Skip to content

Commit f15d1c8

Browse files
authored
Update python-publish.yml
1 parent 1c52418 commit f15d1c8

File tree

1 file changed

+11
-20
lines changed

1 file changed

+11
-20
lines changed

.github/workflows/python-publish.yml

Lines changed: 11 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -12,26 +12,17 @@ on:
1212
release:
1313
types: [published]
1414

15-
permissions:
16-
contents: read
17-
id-token: write
18-
1915
jobs:
20-
deploy:
21-
16+
pypi-publish:
17+
name: upload release to PyPI
2218
runs-on: ubuntu-latest
23-
19+
# Specifying a GitHub environment is optional, but strongly encouraged
20+
environment: release
21+
permissions:
22+
# IMPORTANT: this permission is mandatory for trusted publishing
23+
id-token: write
2424
steps:
25-
- uses: actions/checkout@v3
26-
- name: Set up Python
27-
uses: actions/setup-python@v3
28-
with:
29-
python-version: '3.x'
30-
- name: Install dependencies
31-
run: |
32-
python -m pip install --upgrade pip
33-
pip install build
34-
- name: Build package
35-
run: python -m build
36-
- name: Publish package
37-
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
25+
# retrieve your distributions here
26+
27+
- name: Publish package distributions to PyPI
28+
uses: pypa/gh-action-pypi-publish@release/v1

0 commit comments

Comments
 (0)