Updated Reporting & 24H2 Updates Remediation

This commit is contained in:
Andrew Amason
2025-07-22 09:55:32 -04:00
parent 9c8438d7d1
commit 0092fa4a0f
6 changed files with 86 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
$folder = "$env:SystemRoot\SoftwareDistribution"
$sizeBytes = (Get-ChildItem -Path $folder -Recurse -Force | Measure-Object -Property Length -Sum).Sum
$sizeGB = $sizeBytes / 1GB
if ($sizeGB -gt 10) {
Write-Output 1
exit 1
} else {
Write-Output 0
exit 0
}