Show More
@@ -1615,6 +1615,12 b' relative path alone. The rules are appli' | |||
|
1615 | 1615 | |
|
1616 | 1616 | Alias definitions for templates. See :hg:`help templates` for details. |
|
1617 | 1617 | |
|
1618 | ``templates`` | |
|
1619 | ------------- | |
|
1620 | ||
|
1621 | Use the ``[templates]`` section to define template strings. | |
|
1622 | See :hg:`help templates` for details. | |
|
1623 | ||
|
1618 | 1624 | ``trusted`` |
|
1619 | 1625 | ----------- |
|
1620 | 1626 |
@@ -71,6 +71,20 b' For example,' | |||
|
71 | 71 | defines two symbol aliases, ``r`` and ``rn``, and a function alias |
|
72 | 72 | ``leftpad()``. |
|
73 | 73 | |
|
74 | It's also possible to specify complete template strings, using the | |
|
75 | ``templates`` section. The syntax used is the general template string syntax. | |
|
76 | ||
|
77 | For example, | |
|
78 | ||
|
79 | :: | |
|
80 | ||
|
81 | [templates] | |
|
82 | nodedate = "{node|short}: {date(date, "%Y-%m-%d")}\n" | |
|
83 | ||
|
84 | defines a template, ``nodedate``, which can be called like:: | |
|
85 | ||
|
86 | $ hg log -r . -Tnodedate | |
|
87 | ||
|
74 | 88 | Some sample command line templates: |
|
75 | 89 | |
|
76 | 90 | - Format lists, e.g. files:: |
General Comments 0
You need to be logged in to leave comments.
Login now