ALT Linux Sisyphus discussions
 help / color / mirror / Atom feed
From: "Alexey I. Froloff" <raorn@immo.ru>
To: ALT Devel discussion list <devel@altlinux.ru>
Cc: ALT Linux Sisyphus <sisyphus@altlinux.ru>
Subject: [sisyphus] Q: locale(7) hell
Date: Tue, 14 Dec 2004 11:28:18 +0300
Message-ID: <20041214082818.GA16434@immo.ru> (raw)

[-- Attachment #1: Type: text/plain, Size: 1140 bytes --]

Занялся я тут переписыванием fortune-mod (ну не нравится мне как
оно написано!) и хочу сделать "как в Debian" (C), только лучше
;-)

В двух словах:

При поиске базы fortune(6) перебирает следующие пути:

FORTDIR/%LOCALE%
FORTDIR/%LOCALE_2%
FORTDIR/

где %LOCALE% - язык.  Определяется переменными LC_ALL,
LC_MESSAGES, LANG и LANGUAGE.  %LOCALE% - полное имя локали,
вместе с территорией и кодировкой, %LOCALE_2% - двухсимвольный
код языка.  Rationale: мне (ru_RU.KOI8-R) неинтересно читать
фортунки на белорусском или украинском языках - я просто ничего
не пойму.

С файлами данных в utf-8 тоже всё будет в порядке - fortune-mod
1.99.1, судя по исходникам, рассматривает базы как utf-8 если
видит рядом с базой файл с именем <имя_базы>.u8.

Всвязи с этим вопрос - куда девать ГНУтое расширение под
названием LANGUAGE?  Вариантов два:

LC_ALL
LC_MESSAGES
LANGUAGE.each
LANG

и

LC_ALL
LANGUAGE.each
LC_MESSAGES
LANG

Как правильно?

-- 
Regards, Sir Raorn.
-------------------
Пока мне не объяснят, как сделать так, чтобы воспроизвести это, я буду
считать, что всё нормально.
		-- ldv in devel@

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

             reply	other threads:[~2004-12-14  8:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-14  8:28 Alexey I. Froloff [this message]
2004-12-14  9:05 ` [sisyphus] Re: [devel] " Alexey I. Froloff
2004-12-14  9:27   ` Mike Lykov
2004-12-14 18:39     ` Andrey Rahmatullin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20041214082818.GA16434@immo.ru \
    --to=raorn@immo.ru \
    --cc=devel@altlinux.ru \
    --cc=sisyphus@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Sisyphus discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
		sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
	public-inbox-index sisyphus

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.sisyphus


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git