summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/ikiwiki/directive/tag.mdwn3
-rw-r--r--doc/plugins/tag.mdwn7
-rw-r--r--doc/plugins/tag/discussion.mdwn1
-rw-r--r--doc/plugins/write.mdwn17
-rw-r--r--doc/roadmap.mdwn1
-rw-r--r--doc/todo/auto-create_tag_pages_according_to_a_template.mdwn2
6 files changed, 30 insertions, 1 deletions
diff --git a/doc/ikiwiki/directive/tag.mdwn b/doc/ikiwiki/directive/tag.mdwn
index 807a96f25..c8d9b9816 100644
--- a/doc/ikiwiki/directive/tag.mdwn
+++ b/doc/ikiwiki/directive/tag.mdwn
@@ -19,7 +19,8 @@ instead:
Note that if the wiki is configured to use a tagbase, then the tags will be
located under a base directory, such as "tags/". This is a useful way to
avoid having to write the full path to tags, if you want to keep them
-grouped together out of the way.
+grouped together out of the way. Also, since ikiwiki then knows where to put
+tags, it will automatically create tag pages when new tags are used.
Bear in mind that specifying a tagbase means you will need to incorporate it
into the `link()` [[ikiwiki/PageSpec]] you use: e.g., if your tagbase is
diff --git a/doc/plugins/tag.mdwn b/doc/plugins/tag.mdwn
index 8ff70a069..8e1286e62 100644
--- a/doc/plugins/tag.mdwn
+++ b/doc/plugins/tag.mdwn
@@ -8,6 +8,13 @@ These directives allow tagging pages.
It also provides the `tagged()` [[ikiwiki/PageSpec]], which can be used to
match pages that are tagged with a specific tag.
+The `tagbase` setting can be used to make tags default to being put in a
+particular subdirectory.
+
+The `tag_autocreate` setting can be used to control whether new tag pages
+are created as needed. It defaults to being done only if a `tagbase` is
+set.
+
[[!if test="enabled(tag)" then="""
This wiki has the tag plugin enabled, so you'll see a note below that this
page is tagged with the "tags" tag.
diff --git a/doc/plugins/tag/discussion.mdwn b/doc/plugins/tag/discussion.mdwn
index 03dcb7b2f..dfd749252 100644
--- a/doc/plugins/tag/discussion.mdwn
+++ b/doc/plugins/tag/discussion.mdwn
@@ -28,3 +28,4 @@ See [[todo/auto-create tag pages according to a template]]
-- Jeremy Schultz <jeremy.schultz@uleth.ca>
+`tag_autocreate` can now enable this. --[[Joey]]
diff --git a/doc/plugins/write.mdwn b/doc/plugins/write.mdwn
index 0bf6fcf48..404c3b44f 100644
--- a/doc/plugins/write.mdwn
+++ b/doc/plugins/write.mdwn
@@ -966,6 +966,23 @@ added. Pass it the page that contains the link, and the link text.
An optional third parameter sets the link type. If not specified,
it is an ordinary [[ikiwiki/WikiLink]].
+### `add_autofile($$$)`
+
+Sometimes you may want to add a file to the `srcdir` as a result of content
+of other pages. For example, [[plugins/tag]] pages can be automatically
+created as needed. This function can be used to do that.
+
+The three parameters are the filename to create (relative to the `srcdir`),
+the name of the plugin, and a callback function. The callback will be
+called if it is appropriate to automatically add the file, and should then
+take care of creating it, and doing anything else it needs to (such as
+checking it into revision control). Note that the callback may not always
+be called. For example, if an automatically added file is deleted by the
+user, ikiwiki will avoid re-adding it again.
+
+This function needs to be called during the scan hook, or earlier in the
+build process, in order to add the file early enough for it to be built.
+
## Miscellaneous
### Internal use pages
diff --git a/doc/roadmap.mdwn b/doc/roadmap.mdwn
index 0c7bf2fa8..8e2a01827 100644
--- a/doc/roadmap.mdwn
+++ b/doc/roadmap.mdwn
@@ -78,6 +78,7 @@ Probably incomplete list:
* Make pagespecs match relative by default? (see [[discussion]])
* Flip wikilinks? (see [[todo/link_plugin_perhaps_too_general?]])
* YADA format setup files per default?
+* Enable `tag_autocreate` by default.
In general, we try to use [[ikiwiki-transition]] or forced rebuilds on
upgrade to deal with changes that break compatability. Some things that
diff --git a/doc/todo/auto-create_tag_pages_according_to_a_template.mdwn b/doc/todo/auto-create_tag_pages_according_to_a_template.mdwn
index b05e1db3d..f6d444890 100644
--- a/doc/todo/auto-create_tag_pages_according_to_a_template.mdwn
+++ b/doc/todo/auto-create_tag_pages_according_to_a_template.mdwn
@@ -247,3 +247,5 @@ I've tested it fairly thouroughly. --[[Joey]]
[da5d29f95f6e693e8c14be1b896cf25cf4fdb3c0]: http://git.liegesta.at/?p=ikiwiki.git;a=commitdiff;h=da5d29f95f6e693e8c14be1b896cf25cf4fdb3c0 (commitdiff for da5d29f95f6e693e8c14be1b896cf25cf4fdb3c0)
[a358d74bef51dae31332ff27e897fe04834571e6]: http://git.liegesta.at/?p=ikiwiki.git;a=commitdiff;h=a358d74bef51dae31332ff27e897fe04834571e6 (commitdiff for a358d74bef51dae31332ff27e897fe04834571e6)
[981400177d68a279f485727be3f013e68f0bf691]: http://git.liegesta.at/?p=ikiwiki.git;a=commitdiff;h=981400177d68a279f485727be3f013e68f0bf691 (commitdiff for 981400177d68a279f485727be3f013e68f0bf691)
+
+[[!tag done]]