# HG changeset patch # User Mark Doliner # Date 1190710469 0 # Node ID ecfc73719334d689660e4ee08e7281424c7daf57 # Parent 576dacab8a1fc1595107185314beaff5ed0ed7c5 When running stats.pl, just update the po files in place rather than creating a temporary file which is later deleted. This changes causes the po files to show up as modified in your workspace, but I don't think many people care. There are two benefits to this: 1. When this script is run on pidgin.im it will always only have to account for strings that have changed in the last day, which means it'll run a lot faster 2. The msgmerge'd po files will be put online at http://developer.pidgin.im/l10n/ for the convenience of the translators diff -r 576dacab8a1f -r ecfc73719334 po/stats.pl --- a/po/stats.pl Tue Sep 25 08:47:16 2007 +0000 +++ b/po/stats.pl Tue Sep 25 08:54:29 2007 +0000 @@ -63,17 +63,16 @@ $trans = $fuzz = $untrans = 0; $po = $pos[$index]; print STDERR "$po..." if($ARGV[0] eq '-v'); - system("msgmerge $po.po $PACKAGE.pot -o $po.new 2>/dev/null"); + system("msgmerge -U $po.po $PACKAGE.pot 2>/dev/null"); if (($? & 127) == 2) { printf STDERR "Caught keyboard interrupt--exiting\n"; exit } - $_ = `msgfmt --statistics $po.new -o /dev/null 2>&1`; + $_ = `msgfmt --statistics $po -o /dev/null 2>&1`; chomp; if(/(\d+) translated message/) { $trans = $1; } if(/(\d+) fuzzy translation/) { $fuzz = $1; } if(/(\d+) untranslated message/) { $untrans = $1; } - unlink("$po.new"); $name = ""; $name = $lang{$po};