38 lines
751 B
PowerShell
Executable File
38 lines
751 B
PowerShell
Executable File
param($searchFolder = "X:\gta5\audio\dev_ng\ASSETS\LIPSYNCANIMS\")
|
|
|
|
function GetFiles($searchPath)
|
|
{
|
|
foreach ($item in Get-ChildItem($searchPath))
|
|
{
|
|
if (Test-Path $item.FullName -PathType Container)
|
|
{
|
|
GetFiles $item.FullName
|
|
}
|
|
else
|
|
{
|
|
if((Get-Item $item.FullName).length -eq 0){
|
|
Write-Host $item.FullName
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
Write-Host
|
|
Write-Host “Welcome to find 0 byte files script”
|
|
Write-Host “-----------------------------------”
|
|
|
|
|
|
$searchFolder = $(Get-Item($searchFolder)).FullName
|
|
|
|
Write-Host
|
|
Write-Host "Recursively searching $searchFolder for empty files"
|
|
Write-Host
|
|
|
|
GetFiles($searchFolder)
|
|
|
|
|
|
|