mitre / hipcheck

Automatically assess and score software repositories for supply chain risk.
https://mitre.github.io/hipcheck/
Apache License 2.0
80 stars 6 forks source link

fix: `hc cache` deletion logic #591

Closed j-lanson closed 2 weeks ago

j-lanson commented 2 weeks ago

The cache delete subcommand had a bug in how it was sorting entries to be deleted or preserved, so that -s all would actually choose to keep all instead of delete all entries. Also updated the per-entry deletion logic to also clean up the parent dir (corresponding to github owner) if it was made empty by deleting the child dir.