Take the 2-minute tour ×  I am attempting to rename all
directories and files to uppercase with a shell script. What I
have works, but not for sub directories. As the directory names
are changing during the scripts execution I get things like mv:
cannot stat './def/two/three': No such file or directory  I have
tried using -depth with find so it would rename from the bottom
up. But still run into the same problem. I though about using
cut to break apart the path on / and rename that way, but am at
a loss.  Here's what I have:  for i in `find . -name "*[a-z]*"`
do new_name=`echo $i | tr '[a-z]' '[A-Z]'`     mv $i $new_name
I would appreciate any direction as I feel like this should be a
common task, but failed to find a working solution from some
Google searches.  Please note, I can not use rename as it not
supported by my distro.  share|improve this question I propose a
move to SuperUser. –  Teddy Nov 24 '10 at 16:01 If you have
Perl, rename is an extremely simple Perl script. You can use it
instead of th