CMD Shell
Published in University of Naples "Federico II", Department of Physics, 2021-01-01
Some tips:
- Rename
To rename a single file, use the command Rename-Item “old-file-name.extension” “new-file-name.extension” and press Enter.
To rename multiple files, input the following command and press Enter: **Dir | %{Rename-Item $_ -NewName (“batch-rename-files{0}.jpg” -f $nr++)}** |
ls *.csv | Rename-Item -NewName {$_.name -replace "Default","VOD"}
ls *.dat | Rename-Item -NewName {$_.name -replace "Rvs","R"}
ls *.dat | Rename-Item -NewName {$_.name -replace "Vg","V"}
ls *.dat | Rename-Item -NewName {$_.name -replace "_D",""}
ls *.dat | Rename-Item -NewName {$_.name -replace "2021_","21_T"}