tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* SUMMARY What is equivalent to rename for a global mv
@ 1997-06-18 14:24 managers account
  0 siblings, 0 replies; only message in thread
From: managers account @ 1997-06-18 14:24 UTC (permalink / raw)
  To: tru64-unix-managers

I had an enormous number of replies each with valid methods, too many to 
acknowledge individually so a 'global' thankyou. I particularly liked the 
interactive approach of 

 foreach file (Q*)
          mv $file $file:s/Q/q/
        end


and the piped command


ls -1 Q* | sed '/Q\(.*\)/s//mv Q\1 q\1/' | tcsh

I also received a number of substantial PERL programs which cater for 
name mungeing in more general terms.  I can forward them to anybody 
interested.

I was taken to task for being frustrated in the first place with 
observations that the foreach construction was very powerful, and I do 
acknowledge this.  However, NONE of the solutions is as short as
 PIP Q*=q*/re
!!
To all the ancient warriors out there who miss PIP and sympathised with 
me: vale!
Stuart McKenzie

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1997-06-18 14:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1997-06-18 14:24 SUMMARY What is equivalent to rename for a global mv managers account

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox