pub fn check_disk_space(
ctx: &GuardrailContext,
op: GuardrailOperation,
) -> Option<GuardrailIssue>Expand description
What: Check whether the pacman cache filesystem has enough free space.
Inputs:
ctx: Guardrail context providing cache dir and minimum threshold.op: Transaction kind; removals skip the check (they free space).
Output:
Some(GuardrailIssue::LowDiskSpace)when free space is below the minimum.
Details:
- Falls back to the filesystem root when the cache directory is missing.