[PATCH 2 of 3] template: add revset() template function
Matt Mackall
mpm at selenic.com
Wed Feb 12 17:36:09 CST 2014
On Wed, 2014-02-12 at 17:24 -0800, Durham Goode wrote:
> # HG changeset patch
> # User Durham Goode <durham at fb.com>
> # Date 1392181452 28800
> # Tue Feb 11 21:04:12 2014 -0800
> # Node ID 19aa10a1eff30c475695a239e6dc540d2fc4d851
> # Parent 6c4d00a49f4ce956b8aa60b1352739be3492af78
> template: add revset() template function
>
> Adds a template function that executes a revset and returns the list of
> revisions as the result. It has the signature 'revset(query [, args...])'. The
> args are optional and are applied to the query string using the standard
> python string.format(args) pattern.
We've got revset.formatspec for this purpose, which does smart quoting
and escaping so that we avoid the revset equivalent of SQL injection.
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel
mailing list