update
authorJoey Hess <joey@gnu.kitenet.net>
Tue, 21 Jul 2009 10:38:40 +0000 (12:38 +0200)
committerJoey Hess <joey@gnu.kitenet.net>
Tue, 21 Jul 2009 10:38:40 +0000 (12:38 +0200)
IkiWiki/Plugin/po.pm

index 6aacca53a6ca1635e57143e43847f3b793095ebb..2060ff2087dce09b496e1d076c44f14d388550d2 100644 (file)
@@ -152,13 +152,19 @@ sub checkconfig () {
        push @{$config{wiki_file_prune_regexps}}, qr/\.pot$/;
 
        # Translated versions of the underlays are added if available.
-       foreach my $underlay ("basewiki", map { m/^\Q$config{underlaydirbase}\E\/*(.*)/ } reverse @{$config{underlaydirs}}) {
+       foreach my $underlay ("basewiki",
+                             map { m/^\Q$config{underlaydirbase}\E\/*(.*)/ }
+                                 reverse @{$config{underlaydirs}}) {
                next if $underlay=~/^locale\//;
 
-               # Add underlays containing the po files for slave languages.
+               # Underlay containing pot files.
+               add_underlay("locale/pot/$underlay")
+                       if -d "$config{underlaydirbase}/locale/pot/$underlay";
+
+               # Underlays containing the po files for slave languages.
                foreach my $ll (keys %{$config{po_slave_languages}}) {
-                       add_underlay("locale/mo/$underlay")
-                               if -d "$config{underlaydirbase}/locale/mo/$underlay";
+                       add_underlay("locale/po/$ll/$underlay")
+                               if -d "$config{underlaydirbase}/locale/po/$ll/$underlay";
                }
        
                if ($config{po_master_language}{code} ne 'en') {