From fce8608257c41f239ad3a70ffa07ac6238a4f474 Mon Sep 17 00:00:00 2001 From: Maxwell Muoto <41130755+max-muoto@users.noreply.github.com> Date: Thu, 23 May 2024 00:03:46 -0500 Subject: [PATCH] Deploy job --- .github/workflows/ci.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1be3196..142e1f2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,3 +39,28 @@ jobs: - name: Run pyright run: poetry run pyright + + deploy: + needs: build-and-test + runs-on: macos-latest + if: github.ref == 'refs/heads/main' + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.8' + + - name: Install Poetry + uses: snok/install-poetry@v1.3.1 + + - name: Install dependencies + run: poetry install + + - name: Build and Publish to PyPI + env: + POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_API_TOKEN }} + run: | + poetry build + poetry publish