Skip to content

Commit

Permalink
+2
Browse files Browse the repository at this point in the history
  • Loading branch information
SunSerega committed Apr 25, 2024
1 parent c8bb63f commit 5bbf15e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/on commit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,17 @@ jobs:
git config --global user.email "[email protected]"
git config --global --add url.https://github.com/.insteadOf "[email protected]:"
git checkout --orphan "gh-pages/$(git rev-parse --abbrev-ref HEAD)"
branch_name="gh-pages/$(git rev-parse --abbrev-ref HEAD)"
git checkout --orphan "$branch_name"
mv ".git" "Packing/Reference/0Release/"
cd "Packing/Reference/0Release/"
git add .
git commit -m "Split off gh-pages"
diff=$(git diff origin/$current_branch)
diff=$(git diff "origin/$branch_name")
if [ -n "$diff" ]; then
echo "Differences found. Force pushing the current branch to the remote."
git push -f --set-upstream origin "$(git rev-parse --abbrev-ref HEAD)"
git push -f --set-upstream origin "$branch_name"
else
echo "No differences found"
fi
Expand Down

0 comments on commit 5bbf15e

Please sign in to comment.