Date: Thu, 18 May 2000 15:00:41 -0300 (EST) From: atabraga@bico-de-lacre.iqm.unicamp.br (Ataualpa Albert Carmo Braga) To: questions@freebsd.org Subject: renaming files Message-ID: <20000518180041.385F118C9@bico-de-lacre.iqm.unicamp.br>
index | next in thread | raw e-mail
Try anything like this:
#!/usr/bin/perl
@change='ls *.orig';
foreach $orig (@change){
chop($orig);
$new=$orig;
$new =~ s/orig/new/g;
rename ($orig,$new);
}
Ata.
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000518180041.385F118C9>
