FS#10425 - add i18n (gettext) support to installer

Attached to Project: Release Engineering
Opened by 甘露(Lu Gan) (ganlu) - Friday, 16 May 2008, 05:46 GMT
Last edited by Gerhard Brauer (GerBra) - Thursday, 30 July 2009, 06:47 GMT
Task Type Feature Request
Category ArchISO
Status Closed
Assigned To Simo Leone (neotuli)
Aaron Griffin (phrakture)
Dieter Plaetinck (Dieter_be)
Architecture All
Severity Medium
Priority Normal
Reported Version 2007.08-2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
Currently there is no way to translate our installer, which potentially prevents Archlinux from adopting in foreign (non English spoken) country.

Additional info:
* package version(s)
* config and/or log files etc.


Steps to reproduce:
This task depends upon

Closed by  Gerhard Brauer (GerBra)
Thursday, 30 July 2009, 06:47 GMT
Reason for closing:  Won't implement
Comment by 甘露(Lu Gan) (ganlu) - Friday, 16 May 2008, 05:50 GMT
I think we also need some fonts to support multi-language when installing, more than just get gettext support in the installer.
Comment by Riri (chicha) - Friday, 16 May 2008, 06:55 GMT
Hello,

This is not a bug but a feature request ...
Comment by 甘露(Lu Gan) (ganlu) - Friday, 16 May 2008, 07:58 GMT
Sorry for my carelessness, I didn't notice there has been a "feature request" task type.
Comment by Aaron Griffin (phrakture) - Friday, 16 May 2008, 16:34 GMT
Based on the ML, we may be getting a gettext macro patch soon. I will integrate it if we do
Comment by Abhishek Dasgupta (abhidg) - Wednesday, 11 June 2008, 18:58 GMT
1. Is there any way to do array slicing in bash (like get all but the last two elements of a parameter list)?
2. The x,y coordinates of the dialog boxes are currently hardcoded. Since the translation will cause change
in the string length, it will cause the dialog text to go off-center.

If #1 could be done, then I would change the functions dodialog and msg and incorporate
gettext into them, so that I wouldn't have to go on putting gettext at every
invocation of dodialog/msg.
Comment by Aaron Griffin (phrakture) - Wednesday, 11 June 2008, 19:59 GMT
$ foo=(a b c d e f g h i)

#echo items 1 through 3
$ echo ${foo[@]:1:3}
b c d

#And more complex!
#echo items 1 through length-1
$ echo ${foo[@]:1:$((${#foo[@]} - 1))}
b c d e f g h i
Comment by Abhishek Dasgupta (abhidg) - Thursday, 12 June 2008, 07:09 GMT
Thanks!

I found that directly modifying dodialog could lead to problems later on... so
I added a new function i18n() which works in a manner similar to error() in makepkg
Also I changed the msg() function so that it called i18n, so I didn't have change much
of the msg invocations.

I've attached the patch against the latest HEAD of installer.git
I'll look at it closely later to see if there are any typos that might have creeped in.
Since it's an installer, a typo here could be disastrous :)

I don't know how I can test this other than to build an ISO with this /arch/setup file
and do a install. Is there any other way of testing whether it works properly?


Comment by Simo Leone (neotuli) - Friday, 20 June 2008, 05:43 GMT
This is an important goal for the installer, and will be part of any major change that is made in the near future. However, I'm not going to integrate this into the next release quite yet because well... we don't have any translations yet, and this release needs to get out the door like... now.

Removing from 2008.06 blockers.
Comment by Aaron Griffin (phrakture) - Monday, 30 June 2008, 16:34 GMT
Quick question because I'm lazy and don't want to look it up (hah):
When this patch is applied, how do we generate the base po files for translations? I had an email today regarding Chinese translations, so I'd like to be able to send off something to see if people could begin translating things.

Cheers,
Aaron
Comment by Hugo Doria (hdoria) - Tuesday, 08 July 2008, 16:16 GMT
Aaron,

Try:

xgettext -L Shell setup

It will generate a messages.po file. You can rename it to messages.pot.
Comment by Hugo Doria (hdoria) - Friday, 23 January 2009, 17:26 GMT
I will make a new patch for this. Can i use the archiso from projects.archlinux.org or there is a different branch laying around?
Comment by Dieter Plaetinck (Dieter_be) - Saturday, 24 January 2009, 13:59 GMT
Hey I like this stuff: big improvement, very little changes required in the code. I want to do this with AIF too.
Comment by Dieter Plaetinck (Dieter_be) - Saturday, 28 February 2009, 16:45 GMT
As usual, the bash faq has a great entry about this: http://wooledge.org:8000/BashFAQ/098
Comment by Aaron Griffin (phrakture) - Tuesday, 03 March 2009, 18:32 GMT
@Hugo: Don't use archiso - it doesn't include the installer. The old installer is in installer.git, but it will be replaced with aif.git soon. So I'd translate only that.
Comment by baurzhan.m (cray) - Friday, 19 June 2009, 09:25 GMT
Kazakh translator is ready! Where can I found files to translate?
Comment by Dieter Plaetinck (Dieter_be) - Friday, 24 July 2009, 15:58 GMT
just to be clear: archlinux-installer is deprecated. AIF is the new installer, but it has no support for gettext yet.

BTW: if we enable translations for the installer, does that mean we do it for all other Arch tools too?
In my point of view, all tools could stay in English. I would recommend everyone would at least get a basic notion of English, but I'm okay with having *documentation* in other languages (but all tools still in English)
If you translate one tool, you probably should translate other tools too. (and I think all of that would be too complicated)
Comment by Gerhard Brauer (GerBra) - Thursday, 30 July 2009, 06:46 GMT
I will close this report now. Reasons: the old installer is past. AIF and used tools are per default in English language.
I see no need to translate these into other languages. Our clientele should be able to read enough English to perform the installation.
If one will see this absolutely as a feature a new request should be filed to aif..

Loading...