Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

minor fix to the pypi GHA #219

Merged
merged 1 commit into from
Dec 21, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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