diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 405f29b..85c318c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -25,8 +25,11 @@ jobs: env: PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }} run: | - output=$(poetry publish --build -u __token__ -p $PYPI_TOKEN 2>&1) - if [ $? -ne 0 ]; then - echo "::warning::Version has not been incremented. No new version published." - echo "$output" + # Attempt to publish and capture output + if OUTPUT=$(poetry publish --build -u __token__ -p $PYPI_TOKEN 2>&1); then + echo "Package published successfully" + else + echo "::warning::Not published to PyPi. Poetry output: $OUTPUT" fi + # Ensure step exits successfully + exit 0