summaryrefslogtreecommitdiff
path: root/doc/plugins/write.mdwn
AgeCommit message (Collapse)Author
2010-04-07note about sort and dependency typesJoey Hess
There's a gotcha where pagespec_match_list is used with a dependency type that is not a full content dependency, and so ikiwiki does not know that a content change to a page that sorted too low to match needs to trigger a rebuild, since its sort order may have changed. Inline is mostly ok re this, as it does use content dependencies. Except for in the case of raw mode. But then, page metadata is documented to not be loaded, so it doesn't make sense to use sortspecs that depend on metadata. I hope. :)
2010-04-06Merge remote branch 'smcv/ready/sort-package'Joey Hess
Conflicts: debian/NEWS
2010-04-06improve wording to not encourage explicitly passing undefJoey Hess
2010-04-05Use $a and $b for SortSpec cmp callbacksSimon McVittie
2010-04-04implement typed links; add tagged_is_strict config optionSimon McVittie
2010-04-03Move sort hooks to the IkiWiki::SortSpec namespaceSimon McVittie
Also rename cmpspec_translate (internal function) to sortspec_translate for consistency.
2010-04-03Remove support for check_cmp_foo (pre-sort checks)Simon McVittie
2010-03-25Reimplement extensible sorting mechanisms, in the same way as pagespecsSimon McVittie
2010-03-24Allow sorting to be combined and/or reversedSimon McVittie
2010-03-24Allow hooks to add sorting functions to pagespec_match_listSimon McVittie
2010-02-14add ngettext support & optimize gettext handlingJoey Hess
As I was adding ngettext support, I realized I could optimize the gettext functions by memoizing the creation of the gettext object. Note that the object creation is still deferred until a gettext function is called, to avoid unnecessary startup penalties on code paths that do not need gettext. A side benefit is that separate stub functions are no longer needed to handle the C language case.
2010-02-12formattingJoey Hess
2010-02-12layoutJoey Hess
2010-02-12add highlevel view of when hooks are called during compile and cgi phasesJoey Hess
2010-02-12add variable value examplesJoey Hess
2010-02-12move note to sideboxJoey Hess
2010-02-12heading tweaksJoey Hess
2010-02-12reorg and expand docs of some variablesJoey Hess
2010-02-12add section informationJoey Hess
2010-02-11Group related plugins into sections in the setup file, and drop unused rcs ↵Joey Hess
plugins from the setup file.
2010-01-31document that state variables are not available in the checkconfig hookJoey Hess
2009-11-26htmllink: allow a title attribute to be specifiedJoey Hess
2009-11-08Moved the postscan hook to run on the raw html of a page, before the ↵Joey Hess
template is filled out. This improves the search plugin's indexing, since it will not include navigational elements from the page template or sidebar.
2009-10-09add_depends: optimise influence calculationJoey Hess
I made match_* functions whose influences can vary depending on the page matched set a special "" influence to indicate this. Then add_depends can try just one page, and if static influences are found, stop there.
2009-10-09pagespec_match_list: change limit to filterJoey Hess
2009-10-09pagespec_match_list allow additional pagespec limit parameters againJoey Hess
2009-10-08rename use_pagespec to pagespec_match_listJoey Hess
To avoid breaking plugins, also support the old pagespec_match_list calling convention, with a deprecation warning.
2009-10-08inline: switch to use_pagespecJoey Hess
Taking advantage of every single one of its features, of course. Even had to add one more..
2009-10-08add use_pagespec and deptype functionsJoey Hess
2009-10-07add type info to influence informationJoey Hess
2009-10-07add influence info to match_*Joey Hess
Also update docs, test suite.
2009-10-07mention that pagespec_match returns an overloaded valueJoey Hess
2009-09-10Add genwrapper hook, that can be used to add code into the C wrapper.Joey Hess
2009-07-29add missing backquotehttp://schmonz.livejournal.com/
2009-07-26fix typohttp://schmonz.livejournal.com/
2009-05-19Merge branch 'master' into poJoey Hess
Conflicts: debian/changelog
2009-05-16document longname parameterJon Dowland
2009-05-06Avoid %links accumulating duplicates. (For TOVA)Joey Hess
This is sorta an optimisation, and sorta a bug fix. In one test case I have available, it can speed a page build up from 3 minutes to 3 seconds. The root of the problem is that $links{$page} contains arrays of links, rather than hashes of links. And when a link is found, it is just pushed onto the array, without checking for dups. Now, the array is emptied before scanning a page, so there should not be a lot of opportunity for lots of duplicate links to pile up in it. But, in some cases, they can, and if there are hundreds of duplicate links in the array, then scanning it for matching links, as match_link and some other code does, becomes much more expensive than it needs to be. Perhaps the real right fix would be to change the data structure to a hash. But, the list of links is never accessed like that, you always want to iterate through it. I also looked at deduping the list in saveindex, but that does a lot of unnecessary work, and doesn't completly solve the problem. So, finally, I decided to add an add_link function that handles deduping, and make ikiwiki-transition remove the old dup links.
2009-04-23pagespec_match_list added and used in most appropriate placesJoey Hess
* pagespec_match_list: New API function, matches pages in a list and throws an error if the pagespec is bad. * inline, brokenlinks, calendar, linkmap, map, orphans, pagecount, pagestate, postsparkline: Display a handy error message if the pagespec is erronious.
2009-04-23pagespec error/failure distinction and error display by inlineJoey Hess
* Add IkiWiki::ErrorReason objects, and modify pagespecs to return them in cases where they fail to match due to a configuration or syntax error. * inline: Display a handy error message if the inline cannot display any pages due to such an error. This is perhaps somewhat incomplete, as other users of pagespecs do not display the error, and will eventually need similar modifications to inline. I should probably factor out a pagespec_match_all function and make it throw ErrorReasons.
2009-04-22clarifyJoey Hess
2009-03-08rename hook: run once per file to be renamedintrigeri
... as Joey suggested on todo/need_global_renamepage_hook This hook is applied recursively to returned additional rename hashes, so that it handles the case where two plugins use the hook: plugin A would see when plugin B adds a new file to be renamed. The full set of rename hashes can no longer be changed by hook functions, that are only allowed to return any additional rename hashes it wants to add. Rationale: the correct behavior of the recursion would be hard, if not impossible, to define, if already considered pages were changing on the run. Signed-off-by: intrigeri <intrigeri@boum.org>
2009-03-08Merge commit 'upstream/master' into prv/pointrigeri
Conflicts: IkiWiki/Plugin/editpage.pm debian/control debian/copyright doc/todo/need_global_renamepage_hook.mdwn Signed-off-by: intrigeri <intrigeri@boum.org>
2009-02-19Add noextension parameter to htmlize hooks to support, eg, Makefile.Joey Hess
2009-02-17revert addition of several blank linesJoey Hess
2009-02-16correct WikiLinks to the WikiLink pageAlexandreDupas
2009-02-09document writefile symlink checksJoey Hess
2009-01-27rename hook: instead of modifying the passed-by-name array, return a copyintrigeri
This is intended to solve Joey's concerns expressed on http://ikiwiki.info/todo/need_global_renamepage_hook/, i.e. the need to make it possible to use this hook from external plugins. A plugin using this hook still can add/modify/remove elements of the @torename array. Signed-off-by: intrigeri <intrigeri@boum.org>
2009-01-27revert renamepage's hook original nameintrigeri
Signed-off-by: intrigeri <intrigeri@boum.org>
2009-01-26only pass named parameters to the canremove hookintrigeri
Signed-off-by: intrigeri <intrigeri@boum.org>