Blog‎ > ‎

Rename Files In a Batch

posted Jun 23, 2011, 9:08 AM by Jeremy Walker   [ updated Jun 23, 2011, 3:17 PM ]
I recently had a need for renaming thousands of files in one swoop. I don't usually recommend Java programs, but when Java works and its used right, it works well - and its cross-platform!. So...without further ado....


It worked pretty well, just a little confusing to use. Thank God it previews before committing. Read the How to page before using.

Unfortunately it doesn't hold up well with tons of files and folders. I ended up using an alternative that is for Mac OS X only and suited my need perfectly.


Simply start a Custom project, throw in these actions in order:
  1. Ask for Finder Items
  2. Get Folder Contents
  3. Rename Finder Items
Adjust "Rename Finder Items" to your criteria. Add multiple Rename Finder Items as you see fit. If you want to rename sub-items of the selected folder then checkmark "Repeat for each subfolder found" in the "Get Folder Contents" action.

A third way to do this in a Unix/Linux/OSX Terminal is to use the FIND command with the -exec switch. The brackets "{}" can be used in the sub-command to identify the path to the file in the resulting list. Try this for starters:

find . -exec echo {} \;

That should list the files/folders that it finds in the current directory. Test carefully with other commands like MV or RENAME.