sync_lang.sh now accepts parameters --iconv/--recode for forcing used convertor

This commit is contained in:
Michal Čihař
2002-09-18 08:29:43 +00:00
parent 4c33bf7ee9
commit 0977b64fb9
2 changed files with 28 additions and 10 deletions

View File

@@ -9,6 +9,8 @@ $Source$
* lang/*.php3, tbl_properties_export.php3: removed duplicate message
with typo in name strCvsData (replaced by strStrucCSV)
* lang/czech-*.inc.php3: Updates.
* lang/sync_lang.sh: accepts parameters --iconv/--recode to force
convertor
2002-09-17 Marc Delisle <lem9@users.sourceforge.net>
* lang/spanish: update, thanks to Daniel Hinostroza

View File

@@ -3,14 +3,17 @@
##
# Shell script that synchronises all translations in phpMyAdmin
##
# Any parameters will be passed to grep to filter processed translation, for
# example: './sync_lang.sh czech' will process only czech translation,
# './sync_lang.sh -e czech -e english' will process czech and english
# translations.
# Any parameters (except --iconv/--recode) will be passed to grep to filter
# processed translation, for example: './sync_lang.sh czech' will process only
# czech translation, './sync_lang.sh -e czech -e english' will process czech
# and english translations.
##
# Written by Michal Cihar <nijel at users.sourceforge.net>
##
# Changes:
# 2002-09-18
# * now accepts parameters --iconv/--recode for specifying which convertor
# to use
# 2002-08-13
# * support for synchronisation only for selected language(s)
# 2002-07-18
@@ -25,12 +28,25 @@
# CONVERTOR_PARAMS is used for printf and it also receives two params: source
# and target charset
#
#for iconv
#CONVERTOR=iconv
#CONVERTOR_PARAMS="-f %s -t %s"
#for recode:
CONVERTOR=recode
CONVERTOR_PARAMS="%s..%s"
case "$1" in
--iconv)
echo Using iconv on user request
CONVERTOR=iconv
CONVERTOR_PARAMS="-f %s -t %s"
shift
;;
--recode)
echo Using recode on user request
CONVERTOR=recode
CONVERTOR_PARAMS="%s..%s"
shift
;;
*)
echo Using recode as default, force with --iconv/--recode
CONVERTOR=recode
CONVERTOR_PARAMS="%s..%s"
;;
esac
##