I recommend that you always make transactions before making changes to the working directory, if you are 100% not sure that your changes and the changes that will be merged into your working directory will not conflict.
If you are performing an update ( hg pull; hg update or shorter hg -u pull ) and have any outstanding changes, any changes coming from outside will be merged with your changes. When conflicts happen, it can be difficult to decide what the result of the merger should look like, because you cannot easily distinguish between your changes and those merged into.
When you made your first order, it is much easier to decide what the result of the merger should look like, because you can always look at both parents of the merger. So in reality this is:
hg commithg pull -u (if merging is not required, go to 5)hg mergehg commithg push
Update: As Martin Geisler pointed out, you can get the “original” modified version of the file using:
hg resolve
or for all files at once:
hg resolve --unmark --all hg resolve --tool internal:local -all
However, I believe that the “complete first” system is better. In the end, this is a personal preference ...
source share