[PATCH 3 of 4 V6 STABLE] revert: suggest update on revert to non-parent

Adrian Buehlmann adrian at cadifra.com
Wed Jun 22 01:51:39 CDT 2011


On 2011-06-21 23:06, Matt Mackall wrote:
> On Tue, 2011-06-21 at 09:31 +0200, Adrian Buehlmann wrote:
>> On 2011-06-21 06:11, Kevin Bullock wrote:
>>> # HG changeset patch
>>> # User Kevin Bullock <kbullock at ringworld.org>
>>> # Date 1308626766 18000
>>> # Branch stable
>>> # Node ID ee0ea22c40b86d58437630881ec5ea1815ebe354
>>> # Parent  59f92ee58bc1ff014d11d009ab8e39ae86fb5af7
>>> revert: suggest update on revert to non-parent
>>>
>>> uncommitted changes, revert to non-parent:
>>>
>>>  BEFORE:
>>>    $ hg revert -d 2011-05-05
>>>    Found revision 7423 from Thu May 05 19:56:05 2011 +0200
>>>    abort: no files or directories specified
>>>    (use --all to discard all changes)
>>>
>>>  AFTER:
>>>    $ hg revert -d 2011-05-05
>>>    Found revision 7423 from Thu May 05 19:56:05 2011 +0200
>>>    uncommitted changes
> 
> I don't like the introduction of this new ui.write. Either this text
> should be in the abort hint, or not exist at all.

It exists only in the _change message_ of Kevin's patch - obviously a
copy/paste error he made, which I overlooked myself yesterday (I looked
only at the code part of his patches...).

At least I currently fail to spot any ui.write calls in his patches.

> This is why I earlier proposed:

I think you didn't explain yet *why* you don't like additional ui.write
(or ui.warn or ui.status?) calls.

We could have used ui.warn (which you mentioned yourself before you
settled on the form below).

> ([state note,] action hint)

Technically, these kind of lines were just "hints" until today. Now, you
are adding state notes, which makes these hint lines much longer.

> ..as the general form of these commands.
> 

I fail to see the point of making such long hint lines if we could have
used ui.warn or ui.status instead, but I prefer biting the bullet and
taking long lines instead of no improvement at all.


More information about the Mercurial-devel mailing list