Return to Snippet

Revision: 67166
at August 19, 2014 05:09 by lottegis


Initial Code
get-childItem | rename-item -newname { "$($_.BaseName -replace '_.+$','')$($_.Extension)" }

get-childItem | Where {$_.Extension -eq ".FILEXT"} | rename-item -newname { "$($_.BaseName -replace '_.+$','')$($_.Extension)" }

get-childItem -recurse | rename-item -newname { "$($_.BaseName -replace '_.+$','')$($_.Extension)" }

Initial URL

                                

Initial Description
Change file extension if required

Initial Title
Mass-strip filenames from the first space

Initial Tags

                                

Initial Language
Windows PowerShell