On Tue, Aug 12, 2003 at 05:56:37PM +0100, Richard Urwin wrote:
> On Tuesday 12 Aug 2003 1:43 pm, Todd Slater wrote:
> > When I do for loops I do it like this:
> >
> > for i in *.ogg
> > do
> >     mv "$i" someothername.ogg
> > done
> >
> > the main difference being that the first "i" is not a variable as you
> > have it written; I don't know if having "do" on a new line makes any
> > difference or not.
> >
> > Todd
> 
> OK! got it working! The mystical incantation is:
>   for i in *.ogg
>   do mv "$i" "`echo $i|sed 's/\([_ ]\)\([a-z]\)/\1\u\2/g'`"
>   done
> 
> There's all three types of quote in there, and they are not 
> interchangable. Meditation will bring enlightenment.
> 
> Thank-you, Todd

Cool, glad you got it figured out!

Todd

-- 
Name that tune #18: When you own a big chunk of the bloody third world
the babies just come with the scenery.

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to