Skip to content

Commit

Permalink
Merge pull request #219 from ocefpaf/update_GHA
Browse files Browse the repository at this point in the history
minor fix to the pypi GHA
  • Loading branch information
ocefpaf authored Dec 21, 2022
2 parents ddf1571 + 2dfb32a commit d799c5d
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
name: Publish to PyPI

on: ["push", "pull_request"]
on:
pull_request:
push:
branches:
- main
release:
types:
- published

defaults:
run:
Expand All @@ -15,7 +22,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.x
python-version: "3.x"

- name: Get tags
run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
Expand All @@ -38,7 +45,7 @@ jobs:
python -m twine check *
- name: Publish a Python distribution to PyPI
if: ${{ github.event_name == 'release' }}
if: success() && github.event_name == 'release'
uses: pypa/gh-action-pypi-publish@v1.6.4
with:
user: __token__
Expand Down

0 comments on commit d799c5d

Please sign in to comment.