convert filenames in current directory to lowercase

find my_root_dir -depth -exec rename 's/(.*)\/([^\/]*)/$1\/\L$2/' {} \;

By: evalinux
2009-10-11 07:09:06

9 Alternatives + Submit Alt

What Others Think

Those who wish to convert the file name of the current directory into lowercase can use the code that is added here which will be really beneficial for you that helps in converting the directory name to the lowercase Laws Regarding CBD
Kaitlyn · 20 weeks and 4 days ago
You can learn so many such commands from these websites. Really good to see the details regarding various commands you have specified here. This is one of the best places where you can learn commands. With the above command, you can easily convert filenames in the current directory to lowercase.
Alyssalauren · 16 weeks and 6 days ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this? is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.


Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: