Skip to content

Commit

Permalink
only tags on main are pushed to pypi
Browse files Browse the repository at this point in the history
  • Loading branch information
andped10 committed Mar 15, 2024
1 parent 263ee14 commit 350a46a
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ name: Publish Python Package
on:
workflow_dispatch:
push:
branches: [main]
tags:
- 'v*'

Expand All @@ -18,19 +19,18 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: 3.9

- name: Install dependencies and build
run: |
pip install -e '.[dev]'
python -m build
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_PASSWORD }}

- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: 3.9

- name: Install dependencies and build
run: |
pip install -e '.[dev]'
python -m build
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_PASSWORD }}

0 comments on commit 350a46a

Please sign in to comment.