Skip to content

Commit

Permalink
Merge pull request #3 from Ouranosinc/pypi-deploy
Browse files Browse the repository at this point in the history
add pypi deploy job on tagged release
  • Loading branch information
fmigneault authored Jun 1, 2022
2 parents 8937d16 + fdf2dd8 commit b26ed3c
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Release
on:
- pull_request
- push
- release
- workflow_dispatch

jobs:
deploy_pypi:
if: ${{ success() && (contains(github.ref, 'refs/tags') || github.ref == 'refs/heads/master') }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: "0"
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.9"
- name: Build Distribution Package
run: python setup.py sdist && python setup.py bdist_wheel
- name: Push Package to PyPi
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}

0 comments on commit b26ed3c

Please sign in to comment.