aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki.pm
Commit message (Collapse)AuthorAge
* shorten setuptypeJoey Hess2010-03-19
|
* allow multiple setup file types, and support safe parsingJoey Hess2010-03-19
| | | | | | | | | Finally removed the last hardcoding of IkiWiki::Setup::Standard. Take the first "IkiWiki::Setup::*" in the setup file to define the setuptype, and remember that type to use in dumping later. (But it can be overridden using --set, etc.) Also, support setup file types that are not evaled.
* audited use POSIXJoey Hess2010-03-19
| | | | | | The POSIX perl module exports a huge number of functions by default, so make sure all imports are qualified. (And remove one that was not necessary.)
* add Makefile to exclude exampleJoey Hess2010-03-17
|
* set exclude example to match *.private and improve its descriptionJoey Hess2010-03-17
|
* slight optimisation to file_prunedJoey Hess2010-03-14
| | | | Precompile the regexp, rather than rebuilding on every call.
* Add a include setting, which can be used to make ikiwiki process wiki source ↵Joey Hess2010-03-14
| | | | files, such as .htaccess, that would normally be skipped for security or other reasons. Closes: #447267 (Thanks to Aaron Wilson for the original patch.)
* Improve openid url munging; do not display anchors and cgi parameters, as ↵Joey Hess2010-03-13
| | | | used by yahoo and google urls.
* Add new --clean option; this makes ikiwiki remove all built files in the ↵Joey Hess2010-02-28
| | | | destdir, as well as wrappers and the .ikiwiki directory.
* Loosen regexp, to allow empty quoted parameters in directives.Joey Hess2010-02-26
|
* add ngettext support & optimize gettext handlingJoey Hess2010-02-14
| | | | | | | | | | | 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.
* Allow globs to be used in user() pagespecs.Joey Hess2010-02-11
|
* httpauth: Add httpauth_pagespec setting that can be used to limit pages to ↵Joey Hess2010-02-11
| | | | only being edited via users authed with httpauth.
* update comment re openid library versionJoey Hess2010-02-06
|
* factor out a userpage functionJoey Hess2010-02-04
| | | | Not yet exported, as only 4 quite core plugins use it.
* remove userlink()Joey Hess2010-02-04
| | | | | That was dead code; changes to lockedit and recentchanges removed the last callers.
* fix typoJoey Hess2009-12-14
| | | | | This was probably not noticed because it only results in a warning, and in the checkcontent diff having some unchanged lines in it.
* fix bestlink to not return just-deleted pagesJoey Hess2009-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | bestlink was looking at whether %links existed for a page in order to tell if the page exists, but just-deleted pages still have entries in there (for reasons it may be best not to explore). So bestlink would return just-deleted pages. Instead, make bestlink use %pagesources. Also, when finding a deleted page, %pagecase was not cleared of that page. This, again, made bestlink return just-deleted pages. Now that is cleared. Fixing bestlink exposed another issue though. The backlink calculation code uses bestlink. So when a page was deleted, no backlinks to it are found, and pages that really did backlink to it were not updated, and had broken links. To fix that, the code that actually removes deleted pages had to be split out from find_del_files, so it can run a bit later. It is run just after backlinks are calculated. This way, backlink calculation still sees the deleted pages, but everything afterwards does not. However, it does not address the original bug report that started this whole thing, [[bugs/bestlink_returns_deleted_pages]]. Because there bestlink is run in the needsbuild hook. And that happens before backlink calculation, and so bestlink still returns deleted pages then. Also in the scan hook. If bestlink needs to work consistently during those hooks, a more involved fix will be needed.
* calendar: Add title attributes for all links in the calendars.Joey Hess2009-11-26
|
* htmllink: allow a title attribute to be specifiedJoey Hess2009-11-26
|
* remove debugging and cruftJoey Hess2009-10-13
|
* influence blocker implementationJoey Hess2009-10-13
| | | | | | | | | | | | | | | | | | This avoids unnecessary influences being recorded from pagespecs such as "link(done) and bugs/*", when a page cannot ever possibly match. A pagespec term that returns a value without influence is an influence blocker. If such a blocker has a false value (possibly due to being negated) and is ANDed with another term, it blocks that term's influence from propigating out. If the term is ORed, or has a true value, it does not block influence. (Consider "link(done) or bugs/*" and "link(done) and !nosuchpage") In the implementation in merge_influence, I had to be careful to never negate $this or $other when testing if they are an influence blocker, since negation mutates the object. Thus the slightly weird if statement.
* match_link: dynamic influence needed for page that currently has no linksJoey Hess2009-10-13
|
* add_depends: optimise influence calculationJoey Hess2009-10-09
| | | | | | | | 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.
* rework influence calculationJoey Hess2009-10-09
| | | | | | | | | Thought of a cleaner way to accumulate all influences in pagespec_match_list, using the pagespec_match result object as an accumulator. (This also accumulates all influences from failed matches, rather than just one failed match. I'm not sure if the old method was correct.)
* fix pagespec_match_list handling of list parameterJoey Hess2009-10-09
|
* pagespec_match_list: change limit to filterJoey Hess2009-10-09
|
* pagespec_match_list allow additional pagespec limit parameters againJoey Hess2009-10-09
|
* conditional: use yesnoJoey Hess2009-10-09
|
* rename use_pagespec to pagespec_match_listJoey Hess2009-10-08
| | | | | To avoid breaking plugins, also support the old pagespec_match_list calling convention, with a deprecation warning.
* Merge branch 'master' into dependency-typesJoey Hess2009-10-08
|\ | | | | | | | | | | | | Conflicts: IkiWiki.pm IkiWiki/Render.pm debian/changelog
| * Optimize away most expensive file prune calls, when refreshingJoey Hess2009-10-08
| | | | | | | | | | | | | | | | Benchmarking refresh of a a wiki with 25 thousand pages showed file_pruned() using most of the time. But, when refreshing, ikiwiki already knows about nearly all the files. So we can skip calling file_pruned() for those it knows about. While tricky to do, this sped up a refresh (that otherwise does no work) by 10-50%.
* | use_pagespec: do not fail with error when unable to match, unless it failsJoey Hess2009-10-08
| | | | | | | | with an ErrorReason
* | add use_pagespec and deptype functionsJoey Hess2009-10-08
| |
* | fix handling of influences of pagespecs that fail to matchJoey Hess2009-10-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a pagespec fails to match, I had been throwing the influences away, but that is not right. Consider `backlink(foo)`, where foo does not exist. It still needs to be added as an influence, because if it is created, it will influence the pagespec to match. But with that fix, `link(bar)` had as influences all pages, whether they link to bar or not. Which is not necessary, because modifiying a page to add a link to bar will directly cause the pagespec to match. So, in match_link (and all the match_* functions for page metadata), only return an influence if the match succeeds. match_backlink had been implemented as the inverse of match_link, but that is no longer completly true. While match_link does not return an influence on failure, match_backlink does. match_created_before/after also return the influence on failure, this way if created_after(foo) currently fails because foo does not exist, it will still update the page with the pagespec if foo is created.
* | bugfixJoey Hess2009-10-07
| |
* | add type info to influence informationJoey Hess2009-10-07
| |
* | convert add_depends to use influencesJoey Hess2009-10-07
| | | | | | | | | | | | No more horrible special-case pagespec parsing. OTOH, matching over all pages to determine influences is a lot of work.
* | add influence info to match_*Joey Hess2009-10-07
| | | | | | | | Also update docs, test suite.
* | make success and failreason objects carry an influences hashJoey Hess2009-10-07
| | | | | | | | | | | | | | | | | | | | The hash will be used used to record a set of pages that influenced the result of a pagespec match. The influences are merged together when boolean and/or are encountered in a pagespec. That means using a non-short-circuiting OR operator. And so I use & and | when translating pagespecs, since those bitwise operators can be overloaded. ("and" and "or" cannot, apparently).
* | add_depends should default to content dependencies if unknown type specifiedJoey Hess2009-10-06
| |
* | oops!!Joey Hess2009-10-06
| |
* | support backlink() in pagespecs for links dependenciesJoey Hess2009-10-06
| |
* | implement links dependenciesJoey Hess2009-10-05
| | | | | | | | | | | | | | Involved some code refactoring so that same code that detects link changes for backlinks updating can be used for link dependency checking. The nice thing is that link dep checking is thus comopletly free!
* | add test suite for add_dependsJoey Hess2009-10-04
| | | | | | | | and found a bug in my bitmath..
* | Merge branch 'master' into dependency-typesJoey Hess2009-10-04
|\|
| * remove /i from regexpJoey Hess2009-10-04
| | | | | | | | Nothing case-oriented going on in here.
* | rework dependency types codeJoey Hess2009-10-04
| | | | | | | | | | Simplify, change default content depends number to 1, change interface to make more sense.
* | expand the set of things that can be matched contentlessJoey Hess2009-10-04
| |
* | optimise add_depends for simple pagespecsJoey Hess2009-10-04
| | | | | | | | We don't need to check if the pagespec is contentless; all simple ones are.