Browse Source

Improve performance of pack script.

master
Andrius Štikonas 10 years ago
parent
commit
70b7d35718
2 changed files with 3 additions and 6 deletions
  1. +2
    -5
      pack
  2. +1
    -1
      wrap

+ 2
- 5
pack View File

@@ -43,11 +43,8 @@ for BRANCH in $TRUNK $BRANCHES; do
echo -n "Processing catalog $bfile... ";
d=`echo "$bfile" | sed "s/.$LCODE.po//"`
dirdomain=`echo wesnoth-$d | sed "s/wesnoth-wesnoth/wesnoth/"`
$MSGMERGE --silent "$file" "$file" -o $file.temp
mv $file.temp $file
if [ -f "$BRANCH/$dirdomain/$LCODE.po" ]; then
$MSGMERGE --silent "$BRANCH/$dirdomain/$LCODE.po" "$BRANCH/$dirdomain/$LCODE.po" -o "$BRANCH/$dirdomain/$LCODE.po.temp"
if ! $DIFF -q "$file" "$BRANCH/$dirdomain/$LCODE.po.temp" > /dev/null ; then
if ! $DIFF -q "$file" "$BRANCH/$dirdomain/$LCODE.po" > /dev/null ; then
mkdir "$LCODE-temp/$dirdomain"
cp "$file" "$LCODE-temp/$dirdomain/$LCODE.po"
echo -e $GREEN"OK"$ENDCOLOR
@@ -55,7 +52,7 @@ for BRANCH in $TRUNK $BRANCHES; do
else
echo -e $BLUE"Skipping"$ENDCOLOR
fi
rm "$BRANCH/$dirdomain/$LCODE.po.temp"
rm "$BRANCH/$dirdomain/$LCODE.po"
else
mkdir -p "$LCODE-temp/$dirdomain"
cp "$file" "$LCODE-temp/$dirdomain/$LCODE.po"

+ 1
- 1
wrap View File

@@ -7,6 +7,6 @@ for file in `git ls-files -m *.po`; do
mv $file.temp $file
done

while `ls * | grep temp`; do
while `ls * | grep ".temp"`; do
test
done

Loading…
Cancel
Save