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

Handling values with db_get in case of translation


I'm wondering how would one write postinst script tests, in the case of
"select" debconf configuration values, which are translated in the

Let's say that a package's template contains something like :

 Template: sympa/db_authtype
 Type: select
 Choices: Ident-based, Password
 Choices-fr.UTF-8: Basée sur ident, Mot de passe

If issueing 'db_get sympa/db_authtype', and wanting to test the results, I would expect some code like the following to be correct :

 db_get sympa/db_authtype
   if [ "$RET" = "Ident-based" ]; then

However, it seems that the db_get results depend on the locale, and return "Basée sur ident" instead of "Ident-based" when with french locale...

How can one write scripts, which will not depend on translation of the templates ?

Is this a bug in debconf ?

Btw, that's a real case example in the sympa package, and testing distro (and see bug #466530).

Thanks for your comments.

Best regards,
Olivier BERGER <olivier.berger@it-sudparis.eu> (*NEW ADDRESS*)
http://www-inf.it-sudparis.eu/~olberger/ - OpenPGP-Id: 1024D/6B829EEC
Ingénieur Recherche - Dept INF
Institut TELECOM / TELECOM & Management SudParis (http://www.it-sudparis.eu/), Evry

Reply to: