]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/commitdiff
run po checkconfig last so it can see underlays added in other checkconfig hooks
authorJoey Hess <joey@kitenet.net>
Tue, 25 Jan 2011 19:39:58 +0000 (15:39 -0400)
committerJoey Hess <joey@kitenet.net>
Tue, 25 Jan 2011 19:39:58 +0000 (15:39 -0400)
IkiWiki/Plugin/po.pm
doc/bugs/po:_might_not_add_translated_versions_of_all_underlays.mdwn

index 9ed4a1adb8352f5bb91eb25a424d9cc5f1e1e212..4f8d5036e198b4c0eac2f290156c411907190b87 100644 (file)
@@ -38,7 +38,8 @@ memoize("percenttranslated");
 
 sub import {
        hook(type => "getsetup", id => "po", call => \&getsetup);
-       hook(type => "checkconfig", id => "po", call => \&checkconfig);
+       hook(type => "checkconfig", id => "po", call => \&checkconfig,
+               last => 1);
        hook(type => "needsbuild", id => "po", call => \&needsbuild);
        hook(type => "scan", id => "po", call => \&scan, last => 1);
        hook(type => "filter", id => "po", call => \&filter);
index 66d16bf234b656f0bde0b6ada8c2d1da61d13a72..82aed400d83608e2c86f3f8691b8dc3b179ea3c3 100644 (file)
@@ -6,5 +6,11 @@ of underlays added by a plugin that comes after it in `$config{add_plugins}`;
 for instance, if you have `add_plugins => qw(po smiley)`, you'll probably
 not get the translated versions of `smileys.mdwn`. (I haven't tested this.)
 
+> It doesn't happen because smiley adds the underlay unconditionally on 
+> import. Which is really more usual.
+
 To see them all, `po` should use `last => 1` when registering the hook.
 --[[smcv]]
+
+> At least all that don't last their hooks too! But, added, since
+> it will make the problem much less likely to occur. --[[Joey]] [[done]]