[PATCH V3] extensions: allow extending command synopsis and docstring

Sean Farley sean.michael.farley at gmail.com
Thu Feb 12 14:02:45 CST 2015


Ryan McElroy writes:

> # HG changeset patch
> # User Ryan McElroy <rm at fb.com>
> # Date 1423508565 28800
> #      Mon Feb 09 11:02:45 2015 -0800
> # Node ID ad422dcd2063bf03b50229f56250b624d77997ec
> # Parent  ff5caa8dfd993680d9602ca6ebb14da9de10d5f4
> extensions: allow extending command synopsis and docstring
>
> Mercurial uses a synopsis string and the docstring of a command for the
> command's help output. Today  there is no way for an extension that adds
> functionality to a command to extend either of these help strings.
>
> This patch enables appending to both the doctring and the synopsis, and adds
> a test for this functionality. Example usage is shown in the test and is also
> described in the docstring of extensions.wrapcommand().

This looks good to me.


More information about the Mercurial-devel mailing list