Reputation: 9621
I created a branch for a new feature, and now i want to pull in any changes from the parent branch/baseline?
How can I do this? Is there a way for me to see what will get merged before I actually merge?
--baseline
--> my branch
I want to pull in any changes to 'my branch' from baseline.
Upvotes: 0
Views: 1775
Reputation: 97365
Both previous answers are possible erroneous in the direct interpretation of the terms.
Branch created in the same repo usually, "pulling" from "baseline" to "my branch" can be really merge
Merge
hg up mybranch
hg merge baseline
Upvotes: 2
Reputation: 3173
If you have unsynced changes (see them with hg incoming
), you will have to pull first:
hg pull
Then do the merge:
hg up my-branch; hg merge baseline
You can now inspect your merge result using hg diff
, hg status
, etc
You can allways cancel the merge by doing a hg up --clean
If the merge is ok, then you must commit the result:
hg ci -m 'Merging baseline into my-branch'
Upvotes: 3
Reputation: 2816
You need to pull the changes from the baseline (parent).
hg pull
You can view what changed with a log command:
hg log -P
Then you can merge the changes locally and push back to the baseline. This is all covered in Joel's tutorial.
Upvotes: 0