Bookmarks with hg update question

Steve (Gadget) Barnes gadgetsteve at hotmail.com
Tue Jun 28 06:20:10 UTC 2016



On 27/06/2016 22:35, Jensen, Aaron wrote:
>  
>> > Would it be possible in every bookmark move to automatically place a, possibly 
>> > temporary, bookmark at the pre-move position and mention its existence in the output 
>> > message? This would allow any inadvertent or erroneous bookmark moves to be undone.
> This seems like too much work and bookkeeping. Just don't move bookmarks unless someone asks. Bookmarks and branches should be mostly interchangeable, since bookmarks are intended to be lightweight branches. Replace the word "bookmark" with "branch" and you'll see the current behavior doesn't make sense. Branches tips moving on an update? Yikes!

A mechanism with a lot less work would be to cause **any** operation
that updates a bookmark to output the information: "Updated Bookmark:
Name from Rev X to Rev Y" I haven't looked at the code yet but I suspect
that this would be trivial to add and would at least address those cases
where the intention was not to move the bookmark.

This behaviour would at least provide any user that did care with the
information to be able to reset the bookmark to where it was.
-- 
Steve (Gadget) Barnes
Any opinions in this message are my personal opinions and do not reflect
those of my employer.



More information about the Mercurial mailing list