Skip to content

Commit ecbe369

Browse files
committed
workflows: add release workflow
1 parent 1d0a65f commit ecbe369

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

.github/workflows/release.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
on:
2+
release:
3+
types:
4+
- published
5+
6+
name: release
7+
8+
jobs:
9+
pypi:
10+
name: upload release to PyPI
11+
runs-on: ubuntu-latest
12+
environment: release
13+
permissions:
14+
# Used for OIDC publishing.
15+
# Used to sign the release's artifacts with sigstore-python.
16+
id-token: write
17+
18+
# Used to attach signing artifacts to the published release.
19+
contents: write
20+
21+
steps:
22+
- uses: actions/checkout@v3
23+
24+
- uses: actions/setup-python@v4
25+
with:
26+
python-version: "3.x"
27+
28+
- name: deps
29+
run: python -m pip install -U setuptools build wheel
30+
31+
- name: build
32+
run: python -m build
33+
34+
- name: publish
35+
uses: pypa/[email protected]
36+
37+
- name: sign
38+
uses: sigstore/[email protected]
39+
with:
40+
inputs: ./dist/*.tar.gz ./dist/*.whl
41+
release-signing-artifacts: true
42+
bundle-only: true

0 commit comments

Comments
 (0)