|nevermind I found exactly what I need. For anyone interested here is the code (thanks to CMarini):|
for /d %%x in (*.*) do (
call :Rename %%x
echo Initial count: %count%
for %%f in ("%DirName%\*") do (
if !count! equ 1 ren "%%f" "%DirName%%%~xf"
if !count! gtr 1 ren "%%f" "%DirName% (!count!)%%~xf"
set /a count+=1
echo Incremented count: %count%
For big time noobs, just paste into a .txt file, save as .bat and place the .bat file in the main directory and open the .bat file.