X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=scripts%2Fupdate_translations.php;h=f145c1f0b67206081a60448e739400a33b1e4b5e;hb=a5ed805aeabab3930d066b2777dbab9663bc487f;hp=8120f636f61761e4e32de6296d65edab9f34a83c;hpb=865b716f0919b6e5133133cd6be53f4143660324;p=quix0rs-gnu-social.git diff --git a/scripts/update_translations.php b/scripts/update_translations.php index 8120f636f6..f145c1f0b6 100755 --- a/scripts/update_translations.php +++ b/scripts/update_translations.php @@ -26,11 +26,12 @@ if (isset($_SERVER) && array_key_exists('REQUEST_METHOD', $_SERVER)) { define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); define('STATUSNET', true); +define('LACONICA', true); // compatibility require_once(INSTALLDIR . '/lib/common.php'); // Master StatusNet .pot file location (created by update_pot.sh) -$laconica_pot = INSTALLDIR . '/locale/laconica.po'; +$statusnet_pot = INSTALLDIR . '/locale/statusnet.po'; set_time_limit(60); @@ -43,11 +44,11 @@ foreach ($languages as $language) { $code = $language['lang']; $file_url = 'http://status.net/pootle/' . $code . - '/laconica/LC_MESSAGES/laconica.po'; + '/statusnet/LC_MESSAGES/statusnet.po'; $lcdir = INSTALLDIR . '/locale/' . $code; $msgdir = "$lcdir/LC_MESSAGES"; - $pofile = "$msgdir/laconica.po"; - $mofile = "$msgdir/laconica.mo"; + $pofile = "$msgdir/statusnet.po"; + $mofile = "$msgdir/statusnet.mo"; /* Check for an existing */ if (!is_dir($msgdir)) { @@ -71,7 +72,7 @@ foreach ($languages as $language) { if (sha1($new_file) != $existingSHA1 || !file_exists($mofile)) { echo "Updating ".$code."\n"; file_put_contents($pofile, $new_file); - system(sprintf('msgmerge -U %s %s', $pofile, $laconica_pot)); + system(sprintf('msgmerge -U %s %s', $pofile, $statusnet_pot)); system(sprintf('msgfmt -f -o %s %s', $mofile, $pofile)); } else { echo "Unchanged - ".$code."\n";