Centralised server with http push

Ben Finney bignose+hates-spam at benfinney.id.au
Tue Oct 14 23:41:40 BST 2008


"Lionel Dricot" <zeploum at gmail.com> writes:

> And then, when do I use merge ? What's the difference between pull
> and merge ?

‘pull’ is for maintaining a mirror of a branch. It changes the history
of the current repository so that it matches that of the remote
repository.

The advice I've received here (which I'm now convinced is correct) is:
use ‘pull’ for maintaining a mirror, and not for anything else, since
it is not compatible with maintaining independent history of a branch.


‘merge’ preserves the history of revisions in the current branch, and
applies changes found in a remote branch that has a common ancestor to
this one. It pulls in any revision data needed for this, preserving
intact those revisions that are added, and then thinks really hard
about how best to resolve any divergences. If it can't resolve them
automatically, it marks them as conflicts for the user to resolve.

Use ‘merge’ whenever the current branch is not conceptually
*identical* to the remote branch. This is obviously the case if the
two have divergent history, but remains true for many other cases;
essentially, anything where the local branch is supposed to represent
a different line of development from the remote.

-- 
 \          “It is well to remember that the entire universe, with one |
  `\   trifling exception, is composed of others.” —John Andrew Holmes |
_o__)                                                                  |
Ben Finney




More information about the bazaar mailing list