]> sipb.mit.edu Git - ikiwiki.git/blobdiff - doc/plugins/write.mdwn
Merge branch 'dependency-types' into transitive-dependencies
[ikiwiki.git] / doc / plugins / write.mdwn
index ac093577322a79d67356e8724b7723d6c7a024b1..c244c1f2fd68a92eb325d3b209594b3b35f85768 100644 (file)
@@ -496,6 +496,13 @@ describes the plugin as a whole. For example:
   and undef if a rebuild could be needed in some circumstances, but is not
   strictly required.
 
+### genwrapper
+
+       hook(type => "genwrapper", id => "foo", call => \&genwrapper);
+
+This hook is used to inject C code (which it returns) into the `main`
+function of the ikiwiki wrapper when it is being generated.
+
 ## Plugin interface
 
 To import the ikiwiki plugin interface:
@@ -602,10 +609,17 @@ page created from it. (Ie, it appends ".html".)
 Use this when constructing the filename of a html file. Use `urlto` when
 generating a link to a page.
 
-#### `add_depends($$)`
+#### `add_depends($$;@)`
 
 Makes the specified page depend on the specified [[ikiwiki/PageSpec]].
 
+Additional named parameters can be passed, to indicate what type of
+dependency this is.
+
+Currently, only a "content" parameter is specified. If set to 0, the
+dependency does not involve the content of pages matching the PageSpec, but
+only their existence.
+
 #### `pagespec_match($$;@)`
 
 Passed a page name, and [[ikiwiki/PageSpec]], returns true if the
@@ -641,7 +655,7 @@ pages, as described in [[ikiwiki/SubPage/LinkingRules]].
 
 Many plugins need to generate html links and add them to a page. This is
 done by using the `htmllink` function. The usual way to call
-`htmlllink` is:
+`htmllink` is:
 
        htmllink($page, $page, $link)
 
@@ -850,7 +864,7 @@ of the page with the rcs's conflict markers on failure.
 Passed a message, user, and ip address. Should commit all staged changes.
 Returns undef on success, and an error message on failure.
 
-Changes can be staged by calls to `rcs_add, `rcs_remove`, and
+Changes can be staged by calls to `rcs_add`, `rcs_remove`, and
 `rcs_rename`.
 
 #### `rcs_add($)`