Mercurial > hg
diff tests/test-help.t @ 40414:444861dc1e55
help: displaying documented aliases by default
This makes aliases be displayed in "hg help" when they have a :doc config
entry, and also allows them to be assigned to a category with :category.
Differential Revision: https://phab.mercurial-scm.org/D5087
author | rdamazio@google.com |
---|---|
date | Thu, 18 Oct 2018 19:57:05 -0700 |
parents | fabbf9310025 |
children | dce0e0f78f0f |
line wrap: on
line diff
--- a/tests/test-help.t Sat Oct 13 05:43:39 2018 -0700 +++ b/tests/test-help.t Thu Oct 18 19:57:05 2018 -0700 @@ -823,6 +823,9 @@ > def uisetup(ui): > ui.setconfig(b'alias', b'shellalias', b'!echo hi', b'helpext') > ui.setconfig(b'alias', b'hgalias', b'summary', b'helpext') + > ui.setconfig(b'alias', b'hgalias:doc', b'My doc', b'helpext') + > ui.setconfig(b'alias', b'hgalias:category', b'navigation', b'helpext') + > ui.setconfig(b'alias', b'hgaliasnodoc', b'summary', b'helpext') > > EOF $ echo '[extensions]' >> $HGRCPATH @@ -830,11 +833,28 @@ Test for aliases + $ hg help | grep hgalias + hgalias My doc + $ hg help hgalias hg hgalias [--remote] alias for: hg summary + My doc + + defined by: helpext + + options: + + --remote check for push and pull + + (some details hidden, use --verbose to show complete help) + $ hg help hgaliasnodoc + hg hgaliasnodoc [--remote] + + alias for: hg summary + summarize working directory state This generates a brief summary of the working directory state, including @@ -947,6 +967,7 @@ bisect subdivision search of changesets heads show branch heads + hgalias My doc identify identify the working directory or specified revision log show revision history of entire repository or files @@ -2662,6 +2683,13 @@ hgalias </a> </td><td> + My doc + </td></tr> + <tr><td> + <a href="/help/hgaliasnodoc"> + hgaliasnodoc + </a> + </td><td> summarize working directory state </td></tr> <tr><td>