why does backout in this situation need to merge anything?

Kevin Bullock kbullock+mercurial at ringworld.org
Tue Dec 11 21:22:57 UTC 2012


On 11 Dec 2012, at 3:15 PM, Wujek Srujek wrote:

> I don't think that's the case:
> 1. I create the file with initial contents
> 2. edit file
> 3. edit file again
> 4. add new file and commit
> 
> So, when I backount 3, it is not the immediate parent of my working copy. If it were, I would understand what is happening.

Ahh, yes. The key here is that you added a new file in rev 3 (and didn't touch the original file), so there are no _file contents_ to merge in backing out rev 3.

To put it in lower-level terms, rev 3 is the last entry in the original entry's filelog, so no actual merging needs to be done. Note that this *does* still go thru Mercurial's internal merge machinery (contained in the function mercurial.hg.update).

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock




More information about the Mercurial mailing list