PowerShell Powershell 删除重复文件脚本 PowerShell 脚本删除重复文件(根据文件哈希值判重) 1 2 3 $root_path = "D:\folder_name" $log_file = "D:\log_file.txt" ls $root_path -recurse | get-filehash | group -property hash | where { $_.count -gt 1 } | % { $_.group } | epcsv $log_file