Publish package to PyPI #33
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish package to PyPI | |
on: | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
build-n-publish: | |
name: Build and publish package to PyPI | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v1 | |
with: | |
python-version: "3.9" | |
- name: Install poetry | |
run: | | |
curl -fsS -o get-poetry.py https://install.python-poetry.org | |
python get-poetry.py -y | |
- name: Publish | |
env: | |
PYPI_TOKEN: ${{ secrets.pypi_password }} | |
run: | | |
$HOME/.local/bin/poetry config pypi-token.pypi $PYPI_TOKEN | |
$HOME/.local/bin/poetry publish --build |