Mercurial > hg
view mercurial/templates/gitweb/filediff.tmpl @ 23685:5b1eac343ccd
match: add the abs() method
This is a utility to make it easier for subrepos to convert a file name to the
full path rooted at the top repository. It can replace the various path joining
lambdas, and doesn't require the prefix to be passed into the method that wishes
to build such a path.
The name is derived from the following pattern in annotate() and other places:
name = ((pats and rel) or abs)
The pathname separator is not os.sep in part to avoid confusion with variables
named 'abs' or similar that _are_ '/' separated, and in part because some
methods like cmdutils.forget() and maybe cmdutils.add() need to build a '/'
separated path to the root repo. This can replace the manual path building
there.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Fri, 28 Nov 2014 20:15:46 -0500 |
parents | 9409aeaafdc1 |
children | 30f449378f64 |
line wrap: on
line source
{header} <title>{repo|escape}: diff {file|escape}</title> <link rel="alternate" type="application/atom+xml" href="{url|urlescape}atom-log" title="Atom feed for {repo|escape}"/> <link rel="alternate" type="application/rss+xml" href="{url|urlescape}rss-log" title="RSS feed for {repo|escape}"/> </head> <body> <div class="page_header"> <a href="{logourl}" title="Mercurial" style="float: right;">Mercurial</a> <a href="/">Mercurial</a> {pathdef%breadcrumb} / diff </div> <div class="page_nav"> <a href="{url|urlescape}summary{sessionvars%urlparameter}">summary</a> | <a href="{url|urlescape}shortlog{sessionvars%urlparameter}">shortlog</a> | <a href="{url|urlescape}log{sessionvars%urlparameter}">changelog</a> | <a href="{url|urlescape}graph{sessionvars%urlparameter}">graph</a> | <a href="{url|urlescape}tags{sessionvars%urlparameter}">tags</a> | <a href="{url|urlescape}bookmarks{sessionvars%urlparameter}">bookmarks</a> | <a href="{url|urlescape}branches{sessionvars%urlparameter}">branches</a> | <a href="{url|urlescape}file/{node|short}{path|urlescape}{sessionvars%urlparameter}">files</a> | <a href="{url|urlescape}rev/{node|short}{sessionvars%urlparameter}">changeset</a> | <a href="{url|urlescape}file/{node|short}/{file|urlescape}{sessionvars%urlparameter}">file</a> | <a href="{url|urlescape}file/tip/{file|urlescape}{sessionvars%urlparameter}">latest</a> | <a href="{url|urlescape}log/{node|short}/{file|urlescape}{sessionvars%urlparameter}">revisions</a> | <a href="{url|urlescape}annotate/{node|short}/{file|urlescape}{sessionvars%urlparameter}">annotate</a> | diff | <a href="{url|urlescape}comparison/{node|short}/{file|urlescape}{sessionvars%urlparameter}">comparison</a> | <a href="{url|urlescape}raw-diff/{node|short}/{file|urlescape}">raw</a> | <a href="{url|urlescape}help{sessionvars%urlparameter}">help</a> <br/> </div> <div class="title">{file|escape}</div> <table> {branch%filerevbranch} <tr> <td>changeset {rev}</td> <td style="font-family:monospace"><a class="list" href="{url|urlescape}rev/{node|short}{sessionvars%urlparameter}">{node|short}</a></td></tr> {parent%filediffparent} {child%filediffchild} </table> <div class="list_head"></div> <div class="page_body"> {diff} </div> {footer}