Skip to content

Commit

Permalink
fix(release): exit successfully if the package version is already mat…
Browse files Browse the repository at this point in the history
…ching (#37)
  • Loading branch information
armand-sauzay authored Jun 13, 2024
1 parent e681bdc commit 9492c84
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions release/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,12 @@ runs:
# Commit the bumped project version with a non-semver chore: commit message
git add pyproject.toml
git --no-pager diff --staged
#if there is no change in the version, exit with a warning
if [[ $(git diff --staged) == "" ]]; then
echo "::warning::No changes in version bump, exiting."
exit 0
fi
git commit --author="${{ inputs.git-user-name }} <${{ inputs.git-user-email }}>" -m "chore: release ${{ steps.version.outputs.new_release_version }}" -m "[skip actions]"
# Push the changes to the current (should be main) branch, if this is not a dry-run
Expand Down

0 comments on commit 9492c84

Please sign in to comment.