- @echo off
- PowerShell "$dt=(get-Date).ToString('_MM-dd_HH-mm'); dir _* | ?{($_ -is [IO.FileInfo] -and $_.Extension -eq '.txt') -or $_ -is [IO.DirectoryInfo]} | ren -NewName {($_.BaseName -replace '(?>_\d\d-\d\d){2}$') + $dt + $_.Extension}"
- pause
复制代码
|