ikiwiki/doc/todo/conditional_underlay_files....

11 lines
1.1 KiB
Plaintext
Raw Normal View History

2007-01-18 19:58:48 +01:00
I'd like to see some way to include certain files from the underlay only when the wiki has certain plugins enabled. For example:
* Only include smileys.mdwn and the smileys subdirectory if you enable the [[plugins/smiley]] plugin.
* Only include openid.mdwn if you enable the [[plugins/openid]] plugin.
* Include shortcuts.mdwn only if you enable the [[plugins/shortcut]] plugin.
* Include blog.mdwn only if you don't disable the [[plugins/inline]] plugin.
* Include favicon.ico only if you enable the [[plugins/favicon]] plugin.
* Include wikiicons/diff.png (and the wikiicons directory) only if you enable the CGI.
* Include a hypothetical restructuredtexthelp.rst or similar for other formats only with those formats enabled.
I can see two good ways to implement this. Ideally, with [[conditional_text_based_on_ikiwiki_features]] available, ikiwiki could parse a page like conditionalpages.mdwn, which could contain a set of conditional-wrapped page names; that seems like the most elegant and ikiwiki-like approach. Alternatively, [[/ikiwiki.setup]] could contain a Perl-generated exclude option by default; that would work, but it seems hackish.