Skip to content

Commit

Permalink
chore: bypass commit if no difference
Browse files Browse the repository at this point in the history
  • Loading branch information
hlf20010508 authored Jan 19, 2024
1 parent 24a1ae4 commit 966120b
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,14 @@ jobs:
git config --global user.name $NAME
git config --global user.email $EMAIL
git add -A
git commit -m "chore: update version to $RELEASE_VERSION"
git tag -f $RELEASE_VERSION
git push origin HEAD:master
git push origin HEAD:master --tags -f
if git diff-index --quiet HEAD --; then
echo "Bypass commit."
else
git commit -m "chore: update version to $RELEASE_VERSION"
git tag -f $RELEASE_VERSION
git push origin HEAD:master
git push origin HEAD:master --tags -f
fi
- name: Set up Python
uses: actions/setup-python@v3
with:
Expand Down

0 comments on commit 966120b

Please sign in to comment.