From db88686e755f0431d1af632578e74b17cbff7aec Mon Sep 17 00:00:00 2001 From: Tomer Nosrati Date: Thu, 7 Dec 2023 20:28:56 +0200 Subject: [PATCH] Added CD: .github/workflows/deploy.yml --- .github/workflows/deploy.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/deploy.yml diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 00000000..55734b9f --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,28 @@ +name: Deploy to PyPI + +on: + release: + types: [created] + +jobs: + deploy: + runs-on: ubuntu-latest + env: + POETRY_VIRTUALENVS_CREATE: "false" + steps: + - uses: actions/checkout@v4 + + - name: Install poetry + run: | + pipx install poetry + pipx inject poetry poetry-bumpversion + + - name: Build + run: | + poetry version ${{ github.ref_name }} + poetry build + + - name: Publish + run: | + poetry config pypi-token.pypi ${{ secrets.PYPI_API_TOKEN }} + poetry publish