-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Start adding github actions release activity
- Loading branch information
Devon Ryan
committed
Jan 21, 2025
1 parent
fa851c3
commit 68f051c
Showing
1 changed file
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: pypi | ||
on: [push] | ||
jobs: | ||
pypi: | ||
name: upload to pypi | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.9' | ||
- name: Install build prerequisites | ||
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') | ||
run: | | ||
python -m pip install --upgrade twine build cibuildwheel | ||
- name: sdist | ||
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') | ||
run: | | ||
python -m build --sdist | ||
- name: wheel | ||
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- name: upload | ||
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') | ||
env: | ||
TWINE_USERNAME: "__token__" | ||
TWINE_PASSWORD: ${{ secrets.pypi_password }} | ||
run: | | ||
twine upload dist/* | ||
twine upload wheelhouse/* |