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

Re: Future changes to /usr/games/fortune



On Fri, Jul 11, 2003 at 12:28:30AM +1000, Pascal Hakim wrote:
> Hi,
> 
> I've sent this email to people whom I've got listed as maintaing fortune
> cookies databases. I hope I didn't reach any of you by mistake.
> 
> I have been trying to think of the best way of fixing Bug#178392, and 
> Bug#179595. The issue revolves around the encoding of fortune files.
> 
> My preferred solution at the moment, is to re-encode all the original
> datfiles to UTF-8, and then use iconv to convert fortunes to the current 
> locale at runtime.

I am 100% in favour of this idea


> 
> I am wondering what you think about this proposal. My knowledge of encodings
> is somewhat limited, so if someone has a better solution, I would be glad
> to hear it. I am however, very keen on avoiding any change to the strfile 
> format if I can avoid it.

I think there would be no problems (I am using fortunes in UTF-8 already 
for some time in an UTF-8 environment without any problems at all)

> 
> If we decide to go ahead with this, I would like the change to happen
> uniformly across all fortune cookie databases to avoid problems.

So let me summarize:
1) fortune files (strfile format) are in UTF-8 with no exceptions
whatsoever
2) fortune(6) checks locale[1] and converts output into this locale's
charset.
3) If there are undisplayable characters, fortune(6) either exits with
an error message, or uses TRANSLIT iconv extension (it does not work
properly anyway, but hopefully it will in some time)


2) can be rather easily achieved with a wrapper in perl or python,
while keeping upstream fortune(6) without changes. That however means
fortune would depend on perl or python.

BTW let's move this discussion to debian-i18n. (Reply-To changed)


[1] it is not as easy as it looks, and there are several ad hoc
solutions floating around

-- 
 -----------------------------------------------------------
| Radovan Garabík http://melkor.dnp.fmph.uniba.sk/~garabik/ |
| __..--^^^--..__    garabik @ melkor.dnp.fmph.uniba.sk     |
 -----------------------------------------------------------
Antivirus alert: file .signature infected by signature virus.
Hi! I'm a signature virus! Copy me into your signature file to help me spread!



Reply to: