<div dir="ltr"><div class="gmail_quote">On Thu, Feb 2, 2012 at 2:45 PM, Angel Ezquerra <span dir="ltr"><<a href="mailto:angel.ezquerra@gmail.com">angel.ezquerra@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On Thu, Feb 2, 2012 at 1:35 PM, Idan Kamara <<a href="mailto:idankk86@gmail.com">idankk86@gmail.com</a>> wrote:<br>
> # HG changeset patch<br>
> # User Idan Kamara <<a href="mailto:idankk86@gmail.com">idankk86@gmail.com</a>><br>
> # Date 1328185747 -7200<br>
> # Branch stable<br>
> # Node ID cc7dec00d5016f03acf789c35ce6ef50b204f0cb<br>
> # Parent 0620421044a2bcaafd054a6ee454614888699de8<br>
> commit: add --amend option to amend the parent changeset<br>
><br>
> Commits a new changeset incorporating both the changes to the given files<br>
> and all the changes from the current parent changeset into the repository.<br>
><br>
> You cannot amend public changesets. Amending a changeset with children<br>
> results in a warning (we might want to forbid this).<br>
><br>
> Behind the scenes, first commit the update as a regular child of the current<br>
> parent. Then create a new commit on the parent's parents with the updated<br>
> contents. Then change the working copy parent to this new combined changeset.<br>
> Finally, strip the intermediate commit created in the beginning (might<br>
> want to also strip the amended commit if it has no children).<br>
><br>
> This is an RFC, which last discussed one year ago: <a href="http://markmail.org/message/skalggb4typm27um" target="_blank">http://markmail.org/message/skalggb4typm27um</a><br>
><br>
> I think this attempt is less intrusive and more contained than the previous one<br>
> (it was done quickly to see if there's interest, so still unfinished), with a<br>
> much cleaner implementation (largely due to parren's work on evolution, thanks ;).<br>
><br>
> It doesn't try to be too smart, and now that we have phases it should be safe.<br>
><br>
> This is arguably one of the most common history editing operations. I don't<br>
> think referring people to mq (or rollback, which is worse) for this is particularly good.<br>
> It requires activating a 'heavy' extension and use new commands that the user<br>
> isn't familiar with. This way the user is in familiar territory, knowing all the flags etc.<br>
><br>
<br>
</div></div>This is quite cool and a neat example of what can be done now that<br>
mercurial tracks phases :-)<br>
<br>
One thing that would be nice is to be able to just "amend" the commit<br>
message (without modifying the patch file contents). I think _that_ is<br>
probably _the_ most commonly requested history editing operation (at<br>
least in my experience).<br></blockquote><div><br></div><div>Right. I didn't take care of that yet and due to the current implementation</div><div>it fails with a 'nothing changed' message. But it should be doable.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class="HOEnZb"><font color="#888888"><br>
Angel<br>
</font></span></blockquote></div><br></div>