Saturday, 17 August 2013

git push/fetch - what commits will be synchronized?

git push/fetch - what commits will be synchronized?

I have the following structure of commits in my local git repository:
branch-feature1
|
|-> commit3 -> commit4
|
commit1 -> commit2
|
|-> commit5 -> commit6
|
branch-feature2
1) Am I right to think that when I run git push remote branch-feature1,
only commits from commit1 through commit4 will be synchronized to remote
repository, while commmit5 and commit6 will be left out?
2) Now suppose I have the same commits structure presented above in remote
repository. Am I right to think that when I run 'git fetch remote' I will
have all 6 commits synchronized to my local repository?

No comments:

Post a Comment