Created
July 31, 2017 11:52
-
-
Save blpabhishek/cf1de2d596925ba2405a30fedb881181 to your computer and use it in GitHub Desktop.
Merge two unrelated git repositories
This file contains hidden or 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
# merge project-a to a project-b with all the history | |
cd path/to/project-b | |
git remote add project-a path/to/project-a | |
git fetch project-a | |
git merge --allow-unrelated-histories project-a/master | |
git remote remove project-a | |
git add . | |
git commit -m <message> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment