Przeglądaj źródła

Moving compilepo and mergepo files from locale/ to po/ where they make
more sense to reside. Disregard the po/mo update, though... ;)

graf25 23 lat temu
rodzic
commit
b90b2f5755

+ 0 - 14
locale/compilepo

@@ -1,14 +0,0 @@
-#!/bin/sh
-
-# **
-# ** This script compiles locale PO files
-# **
-# ** Usage:   compilepo <locale id>
-# ** Example: compilepo es
-# **
-# ** Philipe Mingo <mingo@rotedic.com>
-# **
-# **  $Id$
-
-msgfmt -o $1/LC_MESSAGES/squirrelmail.mo $1/LC_MESSAGES/squirrelmail.po
-

+ 0 - 18
locale/mergepo

@@ -1,18 +0,0 @@
-#!/bin/sh
-
-# **
-# ** This script merges global PO to locale PO files.
-# ** It creates a squirrelmail.po.new that have to
-# ** be renamed to squirrelmail.po once before to
-# ** compile the file.
-# **
-# ** Usage:   mergepo <locale id>
-# ** Example: mergepo es
-# **
-# ** Philipe Mingo <mingo@rotedic.com>
-# **
-# **  $Id$
-
-mv $1/LC_MESSAGES/squirrelmail.po $1/LC_MESSAGES/squirrelmail.po.bak 
-msgmerge $1/LC_MESSAGES/squirrelmail.po.bak ../po/squirrelmail.po > $1/LC_MESSAGES/squirrelmail.po
-echo "Old po file renamed to squirrelmail.po.bak "

BIN
locale/ru_RU/LC_MESSAGES/squirrelmail.mo


Plik diff jest za duży
+ 243 - 237
locale/ru_RU/LC_MESSAGES/squirrelmail.po


+ 40 - 0
po/compilepo

@@ -0,0 +1,40 @@
+#!/bin/sh
+
+# **
+# ** This script compiles locale PO files
+# **
+# ** Usage:   compilepo <locale id>
+# ** Example: compilepo es
+# **
+# ** Philipe Mingo <mingo@rotedic.com>
+# ** Konstantin Riabitsev <icon@duke.edu>
+# **
+# **  $Id$
+
+if [ -z "$1" ]; then
+ echo "USAGE: compilepo [localename]"
+ exit 1
+fi
+
+WORKDIR=../locale
+LOCALEDIR=$WORKDIR/$1
+
+if [ ! -d $LOCALEDIR ]; then
+ # lessee if it's been renamed.
+ DCOUNT=`find $WORKDIR/ -name $1* | wc -l` 
+ if [ $DCOUNT -eq 1 ]; then 
+  # aha
+  LOCALEDIR=`find $WORKDIR/ -name $1*`
+ elif [ $DCOUNT -gt 1 ]; then
+  # err out
+  echo "More than one locale matching this name found:"
+  find $WORKDIR/ -name $1*
+  echo "You have to be more specific."
+  exit 1
+ fi
+fi
+
+echo "Compiling $LOCALEDIR/LC_MESSAGES/squirrelmail.po"
+msgfmt -o $LOCALEDIR/LC_MESSAGES/squirrelmail.mo \
+     $LOCALEDIR/LC_MESSAGES/squirrelmail.po
+

+ 45 - 0
po/mergepo

@@ -0,0 +1,45 @@
+#!/bin/sh
+
+# **
+# ** This script merges global PO to locale PO files.
+# ** It creates a squirrelmail.po.new that have to
+# ** be renamed to squirrelmail.po once before to
+# ** compile the file.
+# **
+# ** Usage:   mergepo <locale id>
+# ** Example: mergepo es
+# **
+# ** Philipe Mingo <mingo@rotedic.com>
+# ** Konstantin Riabitsev <icon@duke.edu>
+# **
+# **  $Id$
+
+if [ -z "$1" ]; then
+ echo "USAGE: mergepo [localename]"
+ exit 1
+fi
+
+WORKDIR=../locale
+LOCALEDIR=$WORKDIR/$1
+
+if [ ! -d $LOCALEDIR ]; then
+ # lessee if it's been renamed.
+ DCOUNT=`find $WORKDIR/ -name $1* | wc -l` 
+ if [ $DCOUNT -eq 1 ]; then 
+  # aha
+  LOCALEDIR=`find $WORKDIR/ -name $1*`
+ elif [ $DCOUNT -gt 1 ]; then
+  # err out
+  echo "More than one locale matching this name found:"
+  find $WORKDIR/ -name $1*
+  echo "You have to be more specific."
+  exit 1
+ fi
+fi
+
+echo "Merging $LOCALEDIR/LC_MESSAGES/squirrelmail.po"
+mv $LOCALEDIR/LC_MESSAGES/squirrelmail.po \
+     $LOCALEDIR/LC_MESSAGES/squirrelmail.po.bak 
+msgmerge $LOCALEDIR/LC_MESSAGES/squirrelmail.po.bak ../po/squirrelmail.po > \
+     $LOCALEDIR/LC_MESSAGES/squirrelmail.po
+echo "Old po file renamed to squirrelmail.po.bak "

Niektóre pliki nie zostały wyświetlone z powodu dużej ilości zmienionych plików