Created
December 26, 2019 14:27
-
-
Save arumoy/eeeb40f9e17cd714dc4e5650fbb5d1a3 to your computer and use it in GitHub Desktop.
Rename folder by regex - PowerShell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ChildItem -Directory -Filter "*2019" | Rename-Item -newname { $_.Name -replace "([0-9]{2})-([0-9]{2})-([0-9]{4})", "`$3`-`$2`-`$1` "} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment