I have seen two different ways of merging local branches.
git checkout master
git merge new_feature
git checkout master
git pull . new_feature
What is the difference, pros/cons?
I have seen two different ways of merging local branches.
git checkout master
git merge new_feature
git checkout master
git pull . new_feature
What is the difference, pros/cons?
Locally speaking, there is no difference between merge and pull. When dealing with remotes, "pull" fetches the remote's objects first, then merges with the local branch. But when dealing with local branches, there is nothing to fetch (all objects are already in the local repository) so the "fetch" part of pulling is effectively a no-op. In the local case, then, "pull" is basically the same as just "merge".