PDA

View Full Version : Need an "intelligent" file renamer...


Brian911
11-01-2001, 11:28 AM
Hi all.

I accidently hit a wrong button in my sleeplessness (lol) and removed ALL underscores from my files in one of my /pics/ dirs which is one of the biggest with over 200 sadly :(

the files looked like "Teen_Strip_A.jpg" before, so after an underscore there was always a capital letter.
any renamer that can "find" that out and set an underscore before all capital letters?

I tried ckRename but its not possible with it I think.
and NO, of course that site isnt yet uploaded..

any program/script/whatever that can do it?

thx in advance
Brian

Ace
11-01-2001, 02:40 PM
http://it-falke.com/alatar.de/projects/renamefiles/index.html

I think this will do it.

Jon
11-01-2001, 03:48 PM
try http://www.zdnet.com/downloads/stories/info/0,10615,70933,00.html

Jon

salsbury
11-01-2001, 04:11 PM
cd pics
for old in *.jpg
do
new=`echo $old | sed -e 's/\([a-z0-9]\)\([A-Z]\)/\1_\2/g'`
mv $old $new
done

converts TeenArgBlah.jpg to Teen_Arg_Blah.jpg

Brian911
11-18-2001, 10:39 AM
I tried to forget about that problem actually but still found it again ;)

thanks everybody, I fixed it with both of the programs :D