Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Git: merge branch from different repositories
mkdir joinSamples
cd joinSamples
git init
git remote add sample1 git.yourserver.local/sample1.git
git remote add sample2 git.yourserver.local/sample2.git
git fetch sample1
git fetch sample2
git branch sample1_master sample1/master
git branch sample2_master sample2/master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment