Mercurial > hg
view mercurial/templates/monoblue/branches.tmpl @ 12039:18e1e7520b67 stable
alias: make shadowing behavior more consistent (issue2054)
Currently, given an alias like the following:
[alias]
summary = summary --remote
The alias might be executed - or it might not - depending on the order
of the cmdtable dict.
This happens because cmdalias gets assigned back to the cmdtable like so:
cmdtable['summary'] = ...
Yet '^summary|sum' is still in the table, so which one cmdutil.findcmd()
chooses isn't deterministic.
This patch makes cmdalias assign back to '^summary|sum'. It uses the same
cmdtable key lookup that extensions.wrapcommand() does.
author | Brodie Rao <brodie@bitheap.org> |
---|---|
date | Sat, 21 Aug 2010 22:48:14 -0400 |
parents | 8e0bd0307ba2 |
children | ead4e21f49f1 |
line wrap: on
line source
{header} <title>{repo|escape}: Branches</title> <link rel="alternate" type="application/atom+xml" href="{url}atom-log" title="Atom feed for {repo|escape}"/> <link rel="alternate" type="application/rss+xml" href="{url}rss-log" title="RSS feed for {repo|escape}"/> </head> <body> <div id="container"> <div class="page-header"> <h1><a href="{url}summary{sessionvars%urlparameter}">{repo|escape}</a> / Branches</h1> <form action="{url}log"> {sessionvars%hiddenformentry} <dl class="search"> <dt><label>Search: </label></dt> <dd><input type="text" name="rev" /></dd> </dl> </form> <ul class="page-nav"> <li><a href="{url}summary{sessionvars%urlparameter}">summary</a></li> <li><a href="{url}shortlog{sessionvars%urlparameter}">shortlog</a></li> <li><a href="{url}changelog{sessionvars%urlparameter}">changelog</a></li> <li><a href="{url}graph/{node|short}{sessionvars%urlparameter}">graph</a></li> <li><a href="{url}tags{sessionvars%urlparameter}">tags</a></li> <li class="current">branches</li> <li><a href="{url}file/{node|short}{sessionvars%urlparameter}">files</a></li> </ul> </div> <h2 class="no-link no-border">branches</h2> <table cellspacing="0"> {entries%branchentry} </table> {footer}