diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 47f478b8..7e3a654d 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,6 +1,10 @@ name: Publish Python Package on: + push: + branches: [main] + release: + types: [published] workflow_dispatch: inputs: publish_target: @@ -39,7 +43,7 @@ jobs: run: poetry build - name: Publish to PyPI - if: ${{ github.event.inputs.publish_target == 'pypi' }} + if: github.event_name == 'release' || (github.event_name == 'workflow_dispatch' && github.event.inputs.publish_target == 'pypi') env: PYPI_USERNAME: "__token__" PYPI_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} @@ -47,7 +51,7 @@ jobs: poetry publish --username $PYPI_USERNAME --password $PYPI_PASSWORD - name: Publish to Test PyPI - if: ${{ github.event.inputs.publish_target == 'testpypi' }} + if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.publish_target == 'testpypi') env: PYPI_USERNAME: "__token__" PYPI_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }} diff --git a/.github/workflows/publish_docs.yml b/.github/workflows/publish_docs.yml index ec1b847f..ae327840 100644 --- a/.github/workflows/publish_docs.yml +++ b/.github/workflows/publish_docs.yml @@ -1,6 +1,8 @@ name: Publish Docs on: + release: + types: [published] workflow_dispatch: jobs: diff --git a/pyproject.toml b/pyproject.toml index 2f1177fa..92ff4df8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "aana" -version = "0.2.1" +version = "0.2.2" description = "Multimodal SDK" authors = ["Mobius Labs GmbH "] homepage = "https://www.mobiuslabs.com"