I'm simply trying to have my existing script remove " .RETCH " from the file name.
ex. " B00TI8DTJY.RETCH.PT01.jpg --> B00TI8DTJY.PT01.jpg "
I know how to remove a certain amount of characters or add something to the file name but can't figure out how to Only remove the .RETCH part.
for /f %%a in ('dir *RETCH* /b') do (
set "name=%%a"&set "name=!name:.RETCH=!"
ren "%%a" "!name!"
Just run this on the same directory as your files. If it's needed to go on subdirectories then add
/s flag to