[Top][All Lists]

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

Re: gettext feature request

From: Jean-Jacques Brucker
Subject: Re: gettext feature request
Date: Tue, 27 Jul 2021 22:40:41 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0

Le 27/07/2021 à 16:39, Chet Ramey a écrit :
That's not a good name. It provides no insight about the option or its
purpose. Maybe something like `quote_translation'.
You are right. And I was sorely lacking in imagination.
That's not backwards compatible, so the best thing for you to do would be
to set this option in the places where it matters for your scripts, maybe
in a script configuration file.

IMHO bash already suffers of having too many options. And using, or not, one of those often breaks compatibility.

(example: sourcing different bash files, running incompatible options)

Yet the only case I see which broke backward compatibility, is when this 2 conditions are met :

 * Some piece of code already use TEXTDOMAIN variable and a translation
   feature ($"..." or the gettext.sh shell functions).
 * This piece of code contain at least a /'C-style-string'/ identical
   to a /$"string-to-be-translated"/.

BTW, I now agree this could really happen, then enabling by default a `quote_translation' like this in unacceptable.

Finally there is an other and maybe better solution, by implementing one or two more variables:

 * TEXTCDOMAIN (or TEXTQUOTEDOMAIN): if set, enable `quote_translation'
   feature (like TEXTDOMAIN does for actual translation features).
   TEXTDOMAINDIR does for actual translation features).


 * no additional option
 * backwards compatible


 * probably more complex implementation



Attachment: OpenPGP_signature
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]