Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uflorida!ukma!husc6!ogccse!littlei!omepd!merlyn From: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Newsgroups: comp.unix.questions Subject: Re: simple question about mv Summary: small bugfix Message-ID: <4093@omepd.UUCP> Date: 28 Jan 89 20:33:43 GMT References: <18231@adm.BRL.MIL> Sender: news@omepd.UUCP Reply-To: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Organization: Stonehenge; netaccess via BiiN, Hillsboro, Oregon, USA Lines: 22 In-reply-to: moss@BRL.MIL (VLD/VMB) In article <18231@adm.BRL.MIL>, moss@BRL (VLD/VMB) writes: | Well, this should work under a Bourne shell: | $ for i in *.flip | > do mv $i `basename $i .flip` .flop | > done | $ Almost. Don't try this at home, kiddies. Remove the space before ".flop", or you'll end up with something very unintended. Try this: $ for i in *.flip; do mv $i `basename $i .flip`.flop; done Presto-magico. -- Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 on contract to BiiN (for now :-), Hillsboro, Oregon, USA. ARPA: <@iwarp.intel.com:merlyn@intelob.intel.com> (fastest!) MX-Internet: UUCP: ...[!uunet]!tektronix!biin!merlyn Standard disclaimer: I *am* my employer! Cute quote: "Welcome to Oregon... home of the California Raisins!"