Skip to content

Commit

Permalink
Deal with no changes case
Browse files Browse the repository at this point in the history
  • Loading branch information
lemccomb committed Sep 13, 2023
1 parent dfd70d9 commit 9fecaf7
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,14 @@ jobs:
git fetch
git checkout $GITHUB_HEAD_REF
git add CHANGELOG.md
git commit -m "Update changelog for release"
git push
if git diff-index --quiet HEAD; then
echo "No changes were logged."
else
git commit --allow-empty -m "Update changelog for release"
git push
fi
# git commit -m "Update changelog for release"
# git push

# If this is a pull request build, we're done. Otherwise:
# 1. Create a release.
Expand Down

0 comments on commit 9fecaf7

Please sign in to comment.