Created
February 10, 2012 09:30
-
-
Save oshow/1788021 to your computer and use it in GitHub Desktop.
uniting two git repositories(rough sketch)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~/my_repo1/ | |
git fast-export --all --signed-tags=strip > ~/my_repository.fi | |
cd ~/my_repo2/ | |
git fast-import < ~/my_repository.fi | |
# warning: Not updating refs/heads/master (new tip b3e90632cd34e2f4439ba0e6412c2fae3b7929e3 | |
# does not contain b003578907cd0788e350cb3b69e573f59d6db4b8) | |
# ..... | |
git checkout b3e90632 | |
git checkout -b new_branch | |
git checkout master | |
git merge new_branch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~/my_repo2/ | |
git remote add repo1 ~/my_repo1/ | |
git fetch repo1 | |
git merge repo1/master |
dspinellis
commented
Jul 17, 2014
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment