Skip to content

Commit

Permalink
Added workflow that uploads package to PyPI on commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ZustFancake committed Mar 10, 2024
1 parent 32746cf commit 4c79716
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Publish to PyPI

on:
push:
branches:
- main

jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.x

- name: Install dependencies
run: pip install .

- name: Build and publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*

0 comments on commit 4c79716

Please sign in to comment.