]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki/Plugin/po.pm
avoid hitting the shell with system()
[ikiwiki.git] / IkiWiki / Plugin / po.pm
index 9dda8c0db29d8116acb7e4417276865bbe462897..b8c218c5a98c65db81c14726e5cf26986565dcdc 100644 (file)
@@ -47,7 +47,7 @@ sub getsetup () { #{{{
        return
                plugin => {
                        safe => 0,
-                       rebuild => 1, # format plugin
+                       rebuild => 1, # format plugin & changes html filenames
                },
                po_master_language => {
                        type => "string",
@@ -149,8 +149,7 @@ sub refreshpofiles ($@) { #{{{
 
        foreach my $pofile (@pofiles) {
                if (-e $pofile) {
-                       my $cmd = "msgmerge -U --backup=none $pofile $potfile";
-                       system ($cmd) == 0
+                       system("msgmerge", "-U", "--backup=none", $pofile, $potfile) == 0
                                or error("[po/refreshpofiles:$pofile] failed to update");
                }
                else {