fix: git remote already exists

This commit is contained in:
Khoubza Younes
2022-12-27 02:05:24 +01:00
parent 9ffca7fcc1
commit 9df86f43f7
+1 -2
View File
@@ -7,14 +7,13 @@ CURRENT_BRANCH="main"
function split()
{
# git merge --strategy recursive --strategy-option subtree="$1" "$2/$CURRENT_BRANCH" --allow-unrelated-histories -m "Merge remote-tracking branch '$2/$CURRENT_BRANCH'"
SHA1=$(./bin/splitsh-lite --prefix="$1")
git push $2 "$SHA1:refs/heads/$CURRENT_BRANCH" -f
}
function remote()
{
git remote add "$1" "$2" || git remote set-url "$1" "$2" || true
git remote add "$1" "$2" || true
}
git pull origin $CURRENT_BRANCH