From: Edwin C. <com...@gm...> - 2010-02-02 07:09:18
|
Hi Dave, Here's my 50ct: Every time in Mercurial that you commit to the local cloned repository a new branch is created of the central repository, I presume with it's own head. The remote SF repo is setup such that it cannot contain multiple heads, so if you and I clone it, and I push something first then you will have to merge that changes before your next push, because then you are in a different branch (and you would need different heads to push different branches). If the merged worked fine then it is the new canonical line of development and can be pushed to the head of the central repository without problems. So the cycle is: commit -> push (if no other developer pushed anything before you) or commit -> pull -> update -> merge -> push (if someone pushed other stuff before you) See also: http://www.ivy.fr/mercurial/ref/v1.0/Mercurial-Usage-v1.0.pdf One other nasty thing that I forget sometimes with Hg cmdline is to do 'hg addremove' to actually add and remove files in the local repo. Greetings, Edwin On 2 February 2010 03:41, Dave Koberstein <da...@ko...> wrote: > Hi Edwin, > > I've got a commit. I made it with 'hg commit' Then I tried 'hg push' but > got an error about creating new remote heads. So next I tried an 'hg pull' > and 'hg update'. The pull worked but the update suggested I merge. So now > I've got a successful merge but lots of changed files. Looks like the > recent commits. > > So what do I do? Can I commit this merge? Is that going to do something > funky to the repo when I 'hg push'? I'm tempted to do another checkout just > to be sure I don't mess up anything. > > Davek > > |