powershell rename files code example
Example 1: powershell replace and rename file name
Get-ChildItem -Path "C:\All" -Filter "*.pdf" | Rename-Item -NewName { $_.BaseName.Replace(".","_") + $_.Extension }
Example 2: rename file powershell
mv original_filename.whatever new_filename.whatever
Example 3: powershell bulk rename and add extra string to filename
for %a in (*.*) do ren "%a" "prefix - %a"