ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: Sergey Stepanov <dlagovna@mail.ru>
To: Denis G.Samsonenko <d.g.samsonenko@gmail.com>
Cc: ALT Linux Community <community@lists.altlinux.org>
Subject: Re: [Comm] Неправильная сортировка в консоли?
Date: Fri, 13 Oct 2006 16:26:23 +0400
Message-ID: <E1GYM7L-000K3x-00.dlagovna-mail-ru@f84.mail.ru> (raw)
In-Reply-To: =?koi8-r?Q?<957265820610121923j4ebfc99y111ead8438fdd33c=40mail.gmail.com>?=


> Вам же выше уже написали в сообщении, на которое вы отвечаете, что
> чтобы изменения вами переменной LC_COLLATE (как и любой другой) дошли
> до дочернего процесса, необходимо выполнять не просто "LC_COLLATE=C",
> а "export LC_COLLATE=C". Или пускать вашу ls так:
> 
> ...]$ LC_COLLATE=C ls -1
> 
> Так что таки читать надо что-нибудь по shell (bash), а не про
> локализацию, чтобы понимать, как устанавливать переменные окружения
> среды.

Хорошо. Предположим, мы уже умеем выставлять любую переменную
в любое нужное значение в среде.

Напоминаю исходный вопрос, который мы забыли в ходе обсуждения.


Если LC_COLLATE не выставлено как C, то алгоритм сортировки 
при обработке строк пропускает небуквенные символы. 
Поэтому сортировка "неправильная". Зато по русскому алфавиту.

Если LC_COLLATE=C то строки сортируются в чистом виде, 
не сбрасывая со счетов небуквенные символы. Сортировка
в этом случае "правильная". Но зато не по русскому алфавиту.

Вопрос. Как же сделать так, чтобы и сортировка шла по алфавиту,
и "небуквенные" символы учитывались при сортировке?


Со всяческими пожеланиями, Сергей.
http://xi.net.ru



       reply	other threads:[~2006-10-13 12:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-13 12:26 ` Sergey Stepanov [this message]
2006-10-13 12:36   ` Denis G. Samsonenko

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=E1GYM7L-000K3x-00.dlagovna-mail-ru@f84.mail.ru \
    --to=dlagovna@mail.ru \
    --cc=community@lists.altlinux.org \
    --cc=d.g.samsonenko@gmail.com \
    /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 Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/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 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

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


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