From 410403e466bcc7df5c4eb3ff297f431d48fffb4a Mon Sep 17 00:00:00 2001 From: Ansh Dadwal Date: Sat, 13 Jan 2024 15:45:57 +0530 Subject: [PATCH] Publish to pypi --- .github/workflows/python-publish.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 4375475..8c83658 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -1,11 +1,10 @@ name: Build, Test and Deploy on: + pull_request: push: branches: - main - - develop - jobs: build: runs-on: ${{ matrix.os }} @@ -32,7 +31,7 @@ jobs: python tests/test_color_gen.py test_image.jpg 1 - name: Deploy to PyPI uses: pypa/gh-action-pypi-publish@release/v1 - if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') + if: github.event_name == 'push' && github.ref == 'refs/heads/main' with: user: T-Dynamos password: ${{ secrets.pypi_token }}