OT? Bash Script

Lokrin redhat at lokrin.net
Thu Sep 1 02:54:18 UTC 2005


Well, I don't even know where to start.  If you can point me to the right 
command I could probably google more...

Anyway, I have a directory with several subdirectories in it.  I want to change 
file names in several ways.

1) lower-case everything
2) strip out spaces and special characters.
3) make jpg, jpeg, jpe, etc.. all into jpg

And make sure that nothing collides, such as name.jpg and name.gif.  They have 
to have different names because of another program that makes jpg thumbnails of 
all images.  If necessary I'm willing to rename all the files to something like 
Image0001.jpg, image0002.gif, image0003.gif, etc..  And, if possible, do hidden 
folders and files also.

Anyway, if anyone can get me started I'd appreciate it.

Thanks;

   Lokrin




More information about the redhat-list mailing list