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

Re: [RFC 2] po-sysv: Internationalizing the init scripts





>
>
>
>
>In attachement, a new version of my proposal, hopefully addressing all
>remarks done so far.
>
>please, please, bug it if you feel it should be bugged.
>
>
>Thanks for your time, Mt.
>
Attachment: po-sysv-rfc>


Ok, Comments:

(1) Keep it simple.

Put the po files in /lib. RedHat, Mandrake keep them in
/usr/share; I don't know how they handle unmounted /usr offhand.

Don't ship the po files in packages, or merge, etc;  they are
source. Do something like
# in /etc/init.d/file
DOMAIN=foo  # ie pkg uses /lib/locale/$lang/foo.mo

. /etc/init.d/functions 
# This supplies $ECHO, as shown in previous mails.
# then,

$ECHO "Starting up..."

, and thats all the changes required to the _script_.

Later, /etc/init.d/functions can be changed/experimented with
to provide green OK / graphical icons, etc.

(2) Don't merge the po/mo files.
Provide 1 .po file per package (providing n translated .mo files, of course).

You cannot automatically merge .po files and expect it to work.
A string may be context sensitive, and one source string have
several translations, or be translated slightly differently
by several translators; how does that work? if two packages
both supply the string "Shutting down." but supply slightly
different translations of that string, the merge won't work
automatically. If this is kept within a package, the maintainer
can resolve the issue.  Don't worry too much about the small
size of the po files; correctness is more important.

The setting of LANG is not our problem; its in /etc/environment,
which init will source early on. Remember, some of these
scripts will be run at other times, when LANG may be 
different; the standard mechanism suffices.

(3) Don't use bashisms like $"hello" in init scripts. The
shell is guaranteed _not_ to be bash in many cases.

(4) Don't conflate the problem with debconf. Debconf is a very nice tool, but
not needed or used here.

(5) Additional tools, eg update-po-sysv, etc. are not needed, 
and will conflict with e.g. localepurge. Just place the
compiled .mo files into, eg /lib/locale/<lang>/<foo>.mo

(6) Available console: A font with non-ASCII chars is needed.
Currently the font is set quite late, in S48console-chars.sh,
and a non-ASCII font is not set by default. This could be changed, though; consolechars
is in /usr/bin; moving it
to /bin would help. Non-ASCII fonts are shipped in
console-data, but setting one by default will break 
VESA modes the user has chosen at boot-time. I can't currently
figure out how to detect what mode the user has the machine
in; I might set a debconf question in console-data , defaulting
to "yes", low priority, telling the user do they want 
a non-ASCII font (default latarcyrheb-sun16, for
complete-ish coverage).

Regards,
Alastair McKinstry







>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.2.3 (GNU/Linux)
>
>iD8DBQE/jRDpIiC/MeFF8zQRAnqyAKCcCEcJKJOvqG0phtGLhKSpTAuhpQCfZ+SS
>VamE5emj+liKOVem20QtLMI=
>=2Oha
>-----END PGP SIGNATURE-----
>
>
>
>-- 
>To UNSUBSCRIBE, email to debian-i18n-request@lists.debian.org
>with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

>
>



Reply to: