Page MenuHomeDevCentral

D3225.id8266.diff
No OneTemporary

D3225.id8266.diff

diff --git a/_utils/repo/export-commits-to-manyrepo.sh b/_utils/repo/export-commits-to-manyrepo.sh
--- a/_utils/repo/export-commits-to-manyrepo.sh
+++ b/_utils/repo/export-commits-to-manyrepo.sh
@@ -2,7 +2,7 @@
set -e
-# Parses arguments
+# Parse arguments
if [ $# -lt 1 ]; then
echo "Usage: $0 <TARGET REPOSITORY>" 1>&2
exit 1
@@ -11,15 +11,22 @@
set -x
-# Prepares new main branch for $REPO
+# Ensure we've up-to-date information
+git fetch --all
+
+# Prepare new main branch for $REPO
git subtree split -P "$REPO" -b "$REPO"
# Merge new subtree split branch into main
+git fetch $REPO main
git rebase --strategy-option=ours "$REPO" "$REPO"/main
+git checkout $REPO
+git rebase --strategy-option=ours "$REPO"/main
+
# Push new main
-git push "$REPO" "$REPO"/main:main
+git push "$REPO" "$REPO":main
-# Cleans up
+# Clean up
git checkout main
git branch -D "$REPO"

File Metadata

Mime Type
text/plain
Expires
Mon, Nov 18, 17:38 (17 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2250875
Default Alt Text
D3225.id8266.diff (900 B)

Event Timeline