Skip to content

Commit

Permalink
Only push on 'released', not 'created'
Browse files Browse the repository at this point in the history
  • Loading branch information
stain committed Jul 22, 2020
1 parent 911a06a commit dfc92e2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: Upload Python Package

on:
release:
types: [created]
types: [created, released]

jobs:
deploy:
Expand All @@ -30,7 +30,11 @@ jobs:
echo Please update rocrate/_version.py
false
fi
- name: Test
run: |
python setup.py test
- name: Build and publish
if: "${{ github.event.action == 'released' }}"
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
Expand Down

0 comments on commit dfc92e2

Please sign in to comment.