[rescue] [OT} shell help

Sridhar Ayengar ploopster at gmail.com
Sun Apr 4 08:31:50 CDT 2010

gsm at mendelson.com wrote:
>> Don't forget the quotes around file names ! ! Files can contain spaces
>> and/or other nasty characters !!
> I long ago decided that I would rather have boring file names than ones
> with spaces and other characters. I wrote a PERL prograam to create a
> clean file name, i.e. all lower case characters, anything not a letter
> or number replaced with an underbar, and duplicate or final underbars
> removed.
> It plays hell with Hebrew file names, but I only have those on MP3 files
> from my wife's CDs. :-)
> Note that the awk script will fail if you have more than one level, for
> example, if you have something like
> "us/commerical/jumbo/lockheed_martin/l1011", it won't create the
> intermediate directory levels.
> I like intermediate directory levels, for example, my mp3 library is
> organized as "artist/album/track" or "artist/album/disk/track" for multiple
> disks in an album.

You can deal with this by feeding awk(1) with find(1).

Peace...  Sridhar

More information about the rescue mailing list