Skip to content

Commit

Permalink
add workflow to auto-deploy to pypi on tag creation
Browse files Browse the repository at this point in the history
  • Loading branch information
arogozhnikov committed Sep 9, 2024
1 parent 4062f18 commit fbd1d8c
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/publish-to-pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Deploy to pypi

on:
release:
types: [created]

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

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install dependencies
run: |
pip install . && pip install hatch
- name: Publish to PyPi
env:
HATCH_INDEX_USER: "__token__"
HATCH_INDEX_AUTH: ${{ secrets.PYPI_TOKEN }}
run: |
hatch build --clean && hatch publish

0 comments on commit fbd1d8c

Please sign in to comment.