![]() |
|
We don't bite newbies here... much | |
PerlMonks |
Re: Optimize file renaming.by ivancho (Hermit) |
on May 26, 2005 at 12:02 UTC ( [id://460631]=note: print w/replies, xml ) | Need Help?? |
Update: in all honesty, for my usage I'd have written from the appropriate directory But it's probably best to maintain some readability when messing around with the filesystem Update2: rename($_,substr("000$_",-7)) is even groovier ( borrowed from EdwardG ), although it'll mess you up, if there are longer names, while the previous version won't
In Section
Seekers of Perl Wisdom
|
|