aboutsummaryrefslogtreecommitdiff
path: root/doc/ikiwiki
diff options
context:
space:
mode:
authorJonathon Anderson <anderbubble@gmail.com>2013-01-25 08:42:23 +0300
committerSimon McVittie <smcv@debian.org>2014-09-01 08:54:37 +0100
commit7aa10a2952a0d0ee8543f575966f7e4a780c993c (patch)
tree783fc89f0344a12fadffea9305e689700b11d300 /doc/ikiwiki
parentd5f53139259f57e6554614cede22ed08a59bfce7 (diff)
downloadikiwiki-7aa10a2952a0d0ee8543f575966f7e4a780c993c.tar
ikiwiki-7aa10a2952a0d0ee8543f575966f7e4a780c993c.tar.gz
Provide a UUID in edittemplate templates.
I want to make GUIDs for my RSS feeds that don't change when I move pages around. To that end, I've used UUID::Tiny to generate a version 4 (random) UUID that is presented in a `uuid` variable in the template. At that point, you can do something like this: [[!meta guid="urn:uuid:<TMPL_VAR uuid>"]]
Diffstat (limited to 'doc/ikiwiki')
-rw-r--r--doc/ikiwiki/directive/edittemplate.mdwn12
1 files changed, 9 insertions, 3 deletions
diff --git a/doc/ikiwiki/directive/edittemplate.mdwn b/doc/ikiwiki/directive/edittemplate.mdwn
index a6f301dd3..151fd203a 100644
--- a/doc/ikiwiki/directive/edittemplate.mdwn
+++ b/doc/ikiwiki/directive/edittemplate.mdwn
@@ -27,8 +27,14 @@ something like:
Details:
The template page can also contain [[!cpan HTML::Template]] directives,
-like other ikiwiki [[templates]]. Currently only one variable is
-set: `<TMPL_VAR name>` is replaced with the name of the page being
-created.
+like other ikiwiki [[templates]].
+
+Two variables might be set:
+
+* `<TMPL_VAR name>` is replaced with the name of the page being
+ created.
+
+* `<TMPL_VAR uuid>` is replaced with a version 4 (random) UUID.
+ (Requires the `UUID::Tiny` Perl module.)
[[!meta robots="noindex, follow"]]