diff --git a/.github/workflows/publish_pypi.yml b/.github/workflows/publish_pypi.yml new file mode 100644 index 0000000..f67ef84 --- /dev/null +++ b/.github/workflows/publish_pypi.yml @@ -0,0 +1,32 @@ +name: publish_pypi + +on: + release: + types: created + +jobs: + release: + name: Publish to PyPI + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up Python 3.8 + uses: actions/setup-python@v2 + with: + python-version: "3.8" + + - name: Install Poetry + uses: abatilo/actions-poetry@v2.0.0 + with: + poetry-version: 1.1.6 + + - name: Build + run: poetry build + + - name: Upload + env: + POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }} + run: poetry publish