dirty-helpers/apt-dater-history-prune
2025-09-02 13:09:31 +02:00

9 lines
313 B
Bash
Executable file

#!/usr/bin/env bash
# Prune old apt-dater history
MTIME=+365
find ~/.local/share/apt-dater/history -name meta -mtime $MTIME -exec dirname {} \; | while read history_dir; do
# We are too squeamish to just use rm -rf
rm -f "$history_dir"/{command,meta,timingfile,typescript,failed}
rmdir "$history_dir"
done