On Windows, you can take advantage of PowerShell:
dir | rename-item –newname { $_.name –ireplace '(.+?) 203\.bmp$','$1.bmp' }
In this code snippet we use a command that removes ‘203’ from the file name.
Description
dir => list the content of the current directory
| => send each found element to the next command
rename-item => rename an element in a Windows PowerShell provider namespaceject
–newname => specify the name of the renamed file
{
$_ => points to an object representing the actual file
.name => the name property of the automatic variable
-ireplace => perform a insensitive replace
'(.+?) 203\.bmp$' => here comes the regex for matching the desired files
'$1.bmp' => the replacement string
}
You must run this command inside a power shell. Here is how to start it:
Then cd
into you dir from the Powershell window:
More on http://stackoverflow.com/questions/21837836/how-to-rename-multiple-files-at-once-by-removing-a-varying-part-in-the-file-name
Also – http://superuser.com/questions/236820/how-do-i-remove-the-same-part-of-a-file-name-for-many-files-in-windows-7/871799