Anuerin G. Diaz wrote: >hi john, > > sorry for replying direct but i cant post to the list. ;-) > > here is one post from the local LUG here in the Philippines which >seems to be what you want... > >[quote] >Because FAT is not case sensitive and most, if not all, UNIX filesystems >are. A short script I got from a list of tips as a newbie might help: > > $ for i in *; do mv "$i" "`echo "$i" | tr A-Z a-z`"; done; > >This renames every file in the current directory to all lowercase >filenames. I've added double-quotes around the back-ticked "converter" >to allow it to handle filenames with embedded spaces as well. >[/quote] > >ciao! > >John Richard Smith wrote: > > >>For reasons I need not go into, I transfer *.JPG files across from >>Windblows to Mandrake and work on them in gimp,and >>when I'm finished I have a montage of prints I wish to assemble >>as a composite. >> >>I've hit a snag. >> >>Winblows names it's files in higher case. >>Montage(the programme, part of image magic) seems only willing >>to work with lowercase named files. There are too many to manually >>retype. >> >>How can I convert windblows named *.JPG files to *.jpg named >>files on the command line ? >> >>John >> >> >> > > Here is some of my first efforts, ]# cd /mnt/ext2-vol6/downloads2/digitalcam/set002
set002]# $ for i in *; do mv "$i" "`echo "$i" | tr A-Z a-z`"; done; bash: syntax error near unexpected token `do' set002]# $ for i in *; do mv "$i" "`echo "$i" | tr A-Z a-z`"; bash: syntax error near unexpected token `do' set002]# $ for i in *; mv "$i" "`echo "$i" | tr A-Z a-z`"; done;bash: syntax error near unexpected token `;' set002]# $ for i in * do mv "$i" "`echo "$i" | tr A-Z a-z`"; done; bash: syntax error near unexpected token `;' As a bash script newbie I'm obviously doing something quite wrong here. Any idea what it is, as I think this will work when I learn how to prpoperly execute it. Incidentally, I note there is a pipe so it's a two part operation inwhich the standard output of the first part is fed directly into the standard input of the second element. John -- John Richard Smith [EMAIL PROTECTED]
Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com
