Skip to content

Commit

Permalink
Merge pull request #62 from ianhi/release-action
Browse files Browse the repository at this point in the history
Add github action for releasing
  • Loading branch information
jasongrout authored Mar 11, 2021
2 parents 7ac312d + f419da4 commit b66fc9a
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Publish Package

on:
release:
types: [published]

defaults:
run:
shell: bash -l {0}

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Install node
uses: actions/setup-node@v1
with:
node-version: '13.x'
registry-url: 'https://registry.npmjs.org'

- name: Install Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine jupyter-packaging
- name: Build package
run: python -m build

- name: Publish the Python package
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: twine upload dist/*

0 comments on commit b66fc9a

Please sign in to comment.