Batch renaming files in sub directories
There was a time that i want to change the file name but not only 1 or 2 files, it a lot of files and placed on several directory. How do i do it then? here we go:
Windows command prompt: (If inside a batch file, change %x to %%x)
[code]for /r %x in (*.html) do ren “%x” *.htm[/code]
This also works for renaming the middle of the files
[code]for /r %x in (website*.html) do ren “%x” site*.htm[/code]
Above script was for Windows.
Source: Stackoverflow
Leave a Reply
Want to join the discussion?Feel free to contribute!