We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 77f5b92 commit 4e37ed0Copy full SHA for 4e37ed0
1 file changed
.github/workflows/publish.yml
@@ -0,0 +1,32 @@
1
+name: Publish to PyPI
2
+
3
+on:
4
+ push:
5
+ tags:
6
+ - 'v*' # Only triggers on version tags like v1.0.0
7
8
+jobs:
9
+ build-and-publish:
10
+ name: Build and publish Python 🐍 package
11
+ runs-on: ubuntu-latest
12
13
+ steps:
14
+ - uses: actions/checkout@v4
15
16
+ - name: Set up Python
17
+ uses: actions/setup-python@v5
18
+ with:
19
+ python-version: '3.10' # Adjust if needed
20
21
+ - name: Install build tools
22
+ run: |
23
+ pip install --upgrade build
24
25
+ - name: Build the package
26
27
+ python -m build
28
29
+ - name: Publish to PyPI
30
+ uses: pypa/gh-action-pypi-publish@release/v1
31
32
+ password: ${{ secrets.PYPI_API_TOKEN }}
0 commit comments