Created
July 8, 2019 09:59
-
-
Save PietrH/ead6307fa2442c894eb2859ee31069ff to your computer and use it in GitHub Desktop.
Bulk change the extension of files in a folder in 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 -Path C:\Demo -Filter *.txt | Rename-Item -NewName {[System.IO.Path]::ChangeExtension($_.Name, ".old")} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
An example to change all txt files in the current folder to jpg files with the same filename