Skip to content

Commit e86df6b

Browse files
committed
fix: Preserve exit code of PSR (also run verbose)
The exit code of Python Semantic Release was shadowed by the exit code of the assignment of its output.
1 parent 27682b8 commit e86df6b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.github/workflows/semantic-release.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,15 @@ jobs:
4949
env:
5050
GH_TOKEN: ${{ secrets.SEMANTIC_RELEASE_TOKEN }}
5151
run: |
52-
output=$(semantic-release version 2>&1)
52+
output=$(semantic-release version -v 2>&1)
53+
status=$?
5354
echo "$output"
5455
if echo "$output" | grep -q "The next version is"; then
5556
echo "released=true" >> $GITHUB_OUTPUT
5657
else
5758
echo "released=false" >> $GITHUB_OUTPUT
5859
fi
60+
exit $status
5961
6062
- name: Publish package distributions to PyPI
6163
uses: pypa/gh-action-pypi-publish@release/v1

0 commit comments

Comments
 (0)