[PATCH] extensions: allow replacing command synopsis

Augie Fackler raf at durin42.com
Wed Feb 11 11:26:29 CST 2015


On Feb 11, 2015, at 11:32 AM, Ryan McElroy <rm at fb.com> wrote:

> 
> On 2/11/2015 6:37 AM, Augie Fackler wrote:
>> On Feb 10, 2015, at 10:43 PM, Ryan McElroy <rm at fb.com> wrote:
>> 
>>> # HG changeset patch
>>> # User Ryan McElroy <rm at fb.com>
>>> # Date 1423508565 28800
>>> #      Mon Feb 09 11:02:45 2015 -0800
>>> # Node ID dac1fbb56786c2033e188e7b762a9429cd7ff621
>>> # Parent  ff5caa8dfd993680d9602ca6ebb14da9de10d5f4
>>> extensions: allow replacing command synopsis
>> Hm, interesting. Can you give a sample reason why we should support this?
>> 
> In general, this will allow extensions that wrap/extend commands to be better integrated.
> 
> Specifically, in the remotenames extension, we're adding some new flags to commands -- some examples are --to to the push command, and --all and --remote to bookmarks. Today, you can't edit the synopsis string in the command tuple because tuples and strings are both immutable. The list of args is extensible because it's a list (and editing a list doens't change the tuple that contains it). However, we are unable to add the new flags to the command synopsis. This would allow us to do that.
> 
> I can update the commit message to include these reasons and send out a V2 -- let me know.

Please do. A sample of a synopsis change that remotebranches might be nice too, so that future readers will know the complete rationale.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20150211/221cca67/attachment.pgp>


More information about the Mercurial-devel mailing list