We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 181e033 commit f8a10e3Copy full SHA for f8a10e3
.github/workflows/preview_clear.yml
@@ -36,4 +36,10 @@ jobs:
36
esac
37
' HEAD
38
39
- git push -f origin gh-pages
+ commit_count=$(git rev-list HEAD --count || true)
40
+ if [ -z "$commit_count" ] || [ "$commit_count" = 0 ]; then
41
+ # When no commits are left, we remove the branch
42
+ git push -f origin :gh-pages
43
+ else
44
+ git push -f origin gh-pages
45
+ fi
0 commit comments