mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-04-01 03:36:28 +02:00
Update check-swap-space.ps1
This commit is contained in:
parent
ebd663e34e
commit
1eccb184d8
@ -31,12 +31,12 @@ try {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($Total -eq "0") {
|
if ($Free -ge $MinLevel) {
|
||||||
"⚠️ No swap space."
|
|
||||||
} elseif ($Free -lt $MinLevel) {
|
|
||||||
"⚠️ Swap space has only $Free GB of $Total GB left to use!"
|
|
||||||
} else {
|
|
||||||
"✅ Swap space has $Free GB of $Total GB left."
|
"✅ Swap space has $Free GB of $Total GB left."
|
||||||
|
} elseif ($Total -gt 0) {
|
||||||
|
"⚠️ Swap space has only $Free GB of $Total GB left to use!"
|
||||||
|
} else {
|
||||||
|
"⚠️ No swap space!"
|
||||||
}
|
}
|
||||||
exit 0 # success
|
exit 0 # success
|
||||||
} catch {
|
} catch {
|
||||||
|
Loading…
Reference in New Issue
Block a user