changed update.sh scripts to use intltool

This commit is contained in:
Sven Neumann 2002-02-26 17:37:22 +00:00
parent 3ed06437b4
commit 4ad347fbf7
9 changed files with 52 additions and 135 deletions

View File

@ -1,6 +1,11 @@
2002-02-26 Sven Neumann <sven@gimp.org>
* update.sh: changed to use intltool.
2002-01-31 Stanislav Visnovsky <visnovsky@nenya.ms.mff.cuni.cz>
* sk.po: Updated Slovak translation from Zdenko Podobny <zdpo@mailbox.sk>.
* sk.po: Updated Slovak translation from Zdenko Podobny
<zdpo@mailbox.sk>.
2002-01-28 Christian Rose <menthos@menthos.com>

View File

@ -1,6 +1,7 @@
#!/bin/sh
PACKAGE="gimp14-libgimp"
PATH="$PATH:.."
if [ "x$1" = "x--help" ]; then
@ -8,35 +9,21 @@ echo Usage: ./update.sh langcode
echo --help display this help and exit
echo
echo Examples of use:
echo ./update.sh ----- just creates a new pot file from the source
echo ./update.sh da -- created new pot file and updated the da.po file
echo ./update.sh just creates a new pot file from the source
echo ./update.sh da created new pot file and updated the da.po file
elif [ "x$1" = "x" ]; then
echo "Building the $PACKAGE.pot ..."
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./$PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
intltool-update --gettext-package $PACKAGE --pot
else
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
echo "Building the $PACKAGE.pot ..."
intltool-update --gettext-package $PACKAGE --pot
echo "Now merging $1.po with $PACKAGE.pot, and creating an updated $1.po ..."
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po \
&& rm $1.po.old;
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po && rm $1.po.old;
msgfmt --statistics $1.po
fi;
fi

View File

@ -1,3 +1,7 @@
2002-02-26 Sven Neumann <sven@gimp.org>
* update.sh: changed to use intltool.
2002-01-28 Wang Jian <lark@linux.net.cn>
* zh_CN.po: Updated Simplified Chinese translation by

View File

@ -1,96 +1,29 @@
#!/bin/sh
VERSION="1.2.5"
PACKAGE="gimp14-std-plugins"
PACKAGE="gimp14-std-plug-ins"
PATH="$PATH:.."
if [ "x$1" = "x--help" ]; then
echo Usage: ./update.sh langcode
echo --help display this help and exit
echo --missing search for missing files in POTFILES.in
echo --version shows the version
echo
echo Examples of use:
echo ./update.sh ----- just creates a new pot file from the source
echo ./update.sh da -- created new pot file and updated the da.po file
elif [ "x$1" = "x--version" ]; then
echo "update.sh release $VERSION"
elif [ "x$1" = "x--missing" ]; then
echo "Searching for files containing _( ) but missing in POTFILES.in..."
echo
find ../ -print | egrep '.*\.(c|y|cc|c++|h|gob)' | xargs grep _\( | cut -d: -f1 | uniq | cut -d/ -f2- > POTFILES.in.missing
wait
echo "Sorting data..."
sort -d POTFILES.in -o POTFILES.in &&
sort -d POTFILES.in.missing -o POTFILES.in.missing
wait
echo "Comparing data..."
diff POTFILES.in POTFILES.in.missing -u0 | grep '^+' |grep -v '^+++'|grep -v '^@@' > POTFILES.in.missing
wait
if [ -s POTFILES.ignore ]; then
sort -d POTFILES.ignore -o POTFILES.tmp
echo "Evaluating ignored files..."
wait
diff POTFILES.tmp POTFILES.in.missing -u0 | grep '^+' |grep -v '^+++'|grep -v '^@@' > POTFILES.in.missing
rm POTFILES.tmp
fi
if [ -s POTFILES.in.missing ]; then
echo && echo "Here are the results:"
echo && cat POTFILES.in.missing
echo && echo "File POTFILES.in.missing is being placed in directory..."
echo "Please add the files that should be ignored in POTFILES.ignore"
else
echo &&echo "There are no missing files, thanks God!"
rm POTFILES.in.missing
fi
elif [ "x$1" = "x" ]; then
echo "Building the $PACKAGE.pot ..."
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./$PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
intltool-update --gettext-package $PACKAGE --pot
else
if [ -s $1.po ]; then
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
echo "Building the $PACKAGE.pot ..."
intltool-update --gettext-package $PACKAGE --pot
echo "Now merging $1.po with $PACKAGE.pot, and creating an updated $1.po ..."
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po \
&& rm $1.po.old;
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po && rm $1.po.old;
msgfmt --statistics $1.po
else
echo Sorry $1.po does not exist!
fi;
fi;
fi

View File

@ -1,6 +1,11 @@
2002-02-26 Sven Neumann <sven@gimp.org>
* update.sh: changed to use intltool.
2002-02-25 Stanislav Visnovsky <visnovsky@nenya.ms.mff.cuni.cz>
* sk.po: Updated Slovak translation from Zdenko Podobny <zdpo@mailbox.sk>.
* sk.po: Updated Slovak translation from Zdenko Podobny
<zdpo@mailbox.sk>.
2002-01-28 Wang Jian <lark@linux.net.cn>

View File

@ -1,6 +1,7 @@
#!/bin/sh
PACKAGE="gimp14-script-fu"
PATH="$PATH:.."
if [ "x$1" = "x--help" ]; then
@ -14,40 +15,23 @@ echo ./update.sh da -- created new pot file and updated the da.po file
elif [ "x$1" = "x" ]; then
echo "Building the $PACKAGE.pot ..."
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& ./script-fu-xgettext \
intltool-update --gettext-package $PACKAGE --pot \
&& ./script-fu-xgettext \
../plug-ins/script-fu/scripts/*.scm \
../plug-ins/gap/sel-to-anim-img.scm \
../plug-ins/webbrowser/web-browser.scm \
>> $PACKAGE.po \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./$PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
../plug-ins/webbrowser/web-browser.scm >> $PACKAGE.pot
else
echo "Building the $PACKAGE.pot ..."
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& ./script-fu-xgettext \
intltool-update --gettext-package $PACKAGE --pot \
&& ./script-fu-xgettext \
../plug-ins/script-fu/scripts/*.scm \
../plug-ins/gap/sel-to-anim-img.scm \
../plug-ins/webbrowser/web-browser.scm \
>> $PACKAGE.po \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./$PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
../plug-ins/webbrowser/web-browser.scm >> $PACKAGE.pot
echo "Now merging $1.po with $PACKAGE.pot, and creating an updated $1.po ..."
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po \
&& rm $1.po.old;
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po && rm $1.po.old;
msgfmt --statistics $1.po -o /dev/null
fi;

View File

@ -1,3 +1,8 @@
2002-02-26 Sven Neumann <sven@gimp.org>
* Makefile.am: fixed dependencies.
* update.sh: changed to use intltool.
2002-02-25 Sven Neumann <sven@gimp.org>
* Added ChangeLog.

View File

@ -6,7 +6,7 @@ tips_in_files = gimp-tips.xml.in
tipsdata_DATA = $(tips_in_files:.xml.in=.xml)
%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(srcdir)/*.po)
%.xml: %.xml.in $(GETTEXT_PACKAGE)-tips.pot $(wildcard $(srcdir)/*.po)
$(INTLTOOL_MERGE) $(srcdir) $< $(@) -x -u -c .intltool-merge-cache
$(GETTEXT_PACKAGE)-tips.pot: gimp-tips.xml.in

View File

@ -1,6 +1,7 @@
#!/bin/sh
PACKAGE="gimp14-tips"
PATH="$PATH:.."
if [ "x$1" = "x--help" ]; then
@ -15,23 +16,16 @@ elif [ "x$1" = "x" ]; then
echo "Building the $PACKAGE.pot ..."
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./$PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
intltool-extract --type=gettext/xml gimp-tips.xml.in
intltool-update --gettext-package $PACKAGE --pot
else
xgettext --default-domain=$PACKAGE --directory=.. \
--add-comments --keyword=_ --keyword=N_ \
--files-from=./POTFILES.in \
&& test ! -f $PACKAGE.po \
|| ( rm -f ./PACKAGE.pot \
&& mv $PACKAGE.po ./$PACKAGE.pot );
echo "Building the $PACKAGE.pot ..."
intltool-extract --type=gettext/xml gimp-tips.xml.in
intltool-update --gettext-package $PACKAGE --pot
echo "Now merging $1.po with $PACKAGE.pot, and creating an updated $1.po ..."
mv $1.po $1.po.old && msgmerge $1.po.old $PACKAGE.pot -o $1.po \