From owner-freebsd-questions Thu May 18 11: 0:59 2000 Delivered-To: freebsd-questions@freebsd.org Received: from bico-de-lacre.iqm.unicamp.br (bico-de-lacre.iqm.unicamp.br [143.106.51.234]) by hub.freebsd.org (Postfix) with ESMTP id 7A92137B9B9 for ; Thu, 18 May 2000 11:00:49 -0700 (PDT) (envelope-from atabraga@bico-de-lacre.iqm.unicamp.br) Received: by bico-de-lacre.iqm.unicamp.br (Postfix, from userid 1001) id 385F118C9; Thu, 18 May 2000 15:00:41 -0300 (EST) Subject: renaming files To: questions@freebsd.org Date: Thu, 18 May 2000 15:00:41 -0300 (EST) X-Mailer: ELM [version 2.4ME+ PL54 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-Id: <20000518180041.385F118C9@bico-de-lacre.iqm.unicamp.br> From: atabraga@bico-de-lacre.iqm.unicamp.br (Ataualpa Albert Carmo Braga) Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG 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