[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: boot-floppies state



Sven Rudolph wrote:
> 
> - i18n plan
>   - i18n for C files: use gettext
>   - i18n for shell scripts: rewrite them in C

Well, Michele Dalla Silvestra built the bo rescue disk in italian using
this scheme to add an external file for the i18n translations:

Put all text in some variables and move them at the beginning of the
script, like:


DEFAULTTZ="Your default time zone is set to \$name"
DLCHANGETIT="Change Timezone?"
DLCHANGE="Your current time zone is set to \
`cat /etc/timezone 2>/dev/null`. \
\\nDo you want to change that?"

followed by:

if [ -z "$LANG" -a -n "$LC_MESSAGES" ]
then    LANG=$LC_MESSAGES
elif [ -z "$LANG" -a -n "$LC_ALL" ]
then    LANG=$LC_ALL
fi
I18N="/usr/share/locale/$LANG/timezones.sh"
if [ -r "$I18N" -a ! -w "$I18N" -a ! -x "$I18N" ]
then    . $I18N
fi

then copy the block of variables with english text into the local file
and translate it. Install under /usr/share/locale/$LANG

It works well. (the example was from a dialog version of tzconfig).


>   - i18n for busybox (low priority)
>   - try to keep i18n and localization separated
>     - how many locale data sets will fit on floppy root.bin ?

What about having one rescue disck for every language?


ciao,
Fabrizio
-- 
| fpolacco@icenet.fi    fpolacco@debian.org    fpolacco@pluto.linux.it
| Pluto Leader - Debian Developer & Happy Debian 1.3.1 User - vi-holic
| 6F7267F5 fingerprint 57 16 C4 ED C9 86 40 7B 1A 69 A1 66 EC FB D2 5E


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-devel-request@lists.debian.org . 
Trouble?  e-mail to templin@bucknell.edu .


Reply to: