Skip to content

Commit 898213b

Browse files
committed
handling when nothing changed
1 parent a355ea2 commit 898213b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

.github/workflows/update-hkubectl-downloads.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,14 @@ jobs:
2828
2929
- name: Commit and push updated files to kube-HPC.github.io
3030
run: |
31-
set -e
3231
git config --global user.email "[email protected]"
3332
git config --global user.name "GitHub Action"
3433
git checkout test_branch_1 || git checkout -b test_branch_1 origin/test_branch_1
3534
git add -A
35+
if ! git diff --cached --quiet; then
3636
git commit -m "Update hkubectl download files to the latest release"
3737
git push origin test_branch_1
38+
else
39+
echo "No changes to commit, skipping commit and push."
40+
fi
3841

0 commit comments

Comments
 (0)