ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: Mikhail Zabaluev <mookid@sigent.ru>
To: mandrake-russian@linuxteam.iplabs.ru
Subject: [mdk-re] Re: [mdk-re] Преобразованиерегистра символов
Date: Fri Mar  2 22:11:00 2001
Message-ID: <20010302102104.F2684@localhost.localdomain> (raw)
In-Reply-To: <01030100092906.30174@pif.b5.mephi.ru>; from serpiph@mail.ru on Thu, Mar 01, 2001 at 12:09:29AM +0300

Hello Sergei,

On Thu, Mar 01, 2001 at 00:09 +0300, Sergei wrote:
>
> Среда 28 Февраль 2001 19:39, Вы написали:
> > Приветствую вас, о Русская_Мандрагора!
> >
> >   Требуется порой преобразовывать имена файлов из верхнего регистра в
> >   нижний и обратно. Может, кинет кто примерчиком скрипта?
> Лови (у меня пока работал...):
> #!/usr/bin/perl
> foreach $i (<*>)
> {
> 	$_=$i;
> 	tr#A-Z#a-z#;
> 	$i1=$_;
> 	rename ($i,$i1); 
> }

Короткий вариант "с локальными буквами" (lc/uc - нижний/верхний регистры):

#!/usr/bin/perl
use locale;
rename($_, lc) foreach (<*>);
__END__

-- 
Stay tuned,
  MhZ                                    mailto:mookid@sigent.ru
-----------
To have died once is enough.
		-- Publius Vergilius Maro (Virgil)



  reply	other threads:[~2001-03-02 22:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-02-28 19:38 [mdk-re] ðÒÅÏÂÒÁÚÏ×ÁÎÉÅ ÒÅÇÉÓÔÒÁ ÓÉÍ×ÏÌÏ× äÙÍÙÞ
2001-02-28 21:05 ` [mdk-re] ðÒÅÏÂÒÁÚÏ×ÁÎÉÅÒÅÇÉÓÔÒÁ ÓÉÍ×ÏÌÏ× Sergei
2001-03-02 22:11   ` Mikhail Zabaluev [this message]
2001-03-01 12:26 ` [mdk-re] Re: [mdk-re] Преобразование регистра символов Mikhail Zabaluev
2001-03-01 22:24   ` [mdk-re] Re: [mdk-re] ðÒÅÏÂÒÁÚÏ×ÁÎÉÅÒÅÇÉÓÔÒÁ ÓÉÍ×ÏÌÏ× Sergei
2001-03-02  0:11   ` [mdk-re] Re: [mdk-re] ðÒÅÏÂÒÁÚÏ×ÁÎÉÅ ÒÅÇÉÓÔÒÁ ÓÉÍ×ÏÌÏ× äÙÍÙÞ

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=20010302102104.F2684@localhost.localdomain \
    --to=mookid@sigent.ru \
    --cc=mandrake-russian@linuxteam.iplabs.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 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