I am new to Powershell and i need help in renaming multiple video files. So a folder contains files named as below;
1. Episode S01E01.mkv
2. Episode S01E02.mkv
3. Episode S01E03.mkv
…
…
350. Episode S01E350.mkv
I am trying to build a script that would change the file name from Episode S01E*.mkv to "S01E*.mkv.
I tried to use this script but for the life of me i cannot modify it to my requirement;
$counter = 01
Get-ChildItem *.mkv | ForEach-Object {$newName = "S01E$counter" + $_.Extension Rename-Item $_.FullName -NewName $newName $counter++}