We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent da2c8e5 commit 3b699d0Copy full SHA for 3b699d0
1 file changed
.github/workflows/publish.yml
@@ -0,0 +1,31 @@
1
+name: Publish to PyPI
2
+
3
+on:
4
+ push:
5
+ tags:
6
+ - "v*" # Only publish on version tags like v0.1.0
7
8
+jobs:
9
+ build-and-publish:
10
+ runs-on: ubuntu-latest
11
12
+ steps:
13
+ - uses: actions/checkout@v4
14
15
+ - name: Set up Python
16
+ uses: actions/setup-python@v5
17
+ with:
18
+ python-version: "3.12"
19
20
+ - name: Install build tools
21
+ run: |
22
+ pip install build twine
23
24
+ - name: Build package
25
+ run: python -m build
26
27
+ - name: Publish to PyPI
28
+ run: twine upload dist/*
29
+ env:
30
+ TWINE_USERNAME: __token__
31
+ TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
0 commit comments