Skip to content

Commit

Permalink
feat: specify the strategy of merging
Browse files Browse the repository at this point in the history
  • Loading branch information
AlaRduTP committed Mar 21, 2024
1 parent e02ce02 commit afcb770
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/merge-all.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

if [ $# -ne 1 ]; then
echo "./merge-all.sh <commit-message>"
echo "$0 <commit-message>"
exit 1
fi

Expand All @@ -17,7 +17,7 @@ for branch in $(git branch -r | grep -v HEAD); do
echo "Checkout failed for branch $branch"
exit 1
fi
git merge --squash main
git merge --squash -s recursive -X theirs main
if [[ $? -ne 0 ]]; then
echo "Merge failed for branch $branch"
exit 1
Expand All @@ -26,4 +26,4 @@ for branch in $(git branch -r | grep -v HEAD); do
fi
done

git checkout main
git checkout main

0 comments on commit afcb770

Please sign in to comment.