It sounds like you haven't made any commits, which means that the history looks like this:
... [a] --- [b] --- (wc)
\
`--- [c] --- [d]
Here your dirty working copy is based on b
and you pulled down c
and d
.
Since there are no commits, there is nothing to merge. You can simply update:
$ hg update
and your modifications will be merged with the changes in c
and d
to produce this graph:
... [a] --- [b] --- [c] --- [d] --- (wc)
If you had made one or more commits, but haven't pushed them anywhere, then you could use the rebase extension to rebuild (re-play) the commits onto a different base. There you start with
... [a] --- [b] --- [x] --- [y]
You pull from the main repository to get:
... [a] --- [b] --- [x] --- [y]
\
`--- [c] --- [d]
After running hg rebase
you end up with
... [a] --- [b] --- [c] --- [d] --- [x'] --- [y']
where x'
and y'
are the rebased versions of x
and y
, respectively. You can repeat this procedure as long as you haven't pushed your branch anywhere (Mercurial tracks the "phase" of each changeset, and when you push a changeset somewhere it moves from the draft
phase to the public
phase).