feat: add adaptive SMART refresh controls (#96)

This commit is contained in:
Gustavo Rosa
2026-07-24 14:13:17 -04:00
committed by GitHub
parent 27c6a808da
commit ff289e523f
14 changed files with 512 additions and 89 deletions
+28
View File
@@ -0,0 +1,28 @@
#!/usr/bin/env bash
set -euo pipefail
if (( EUID != 0 )); then
echo "Run this command through the administrator authorization dialog." >&2
exit 1
fi
if (($# != 1)) || [[ "$1" != "start" && "$1" != "pause" ]]; then
echo "usage: $0 {start|pause}" >&2
exit 2
fi
service_name="noctalia-drive-health"
case "$1" in
start)
systemctl daemon-reload
systemctl enable --now "$service_name.timer"
systemctl start "$service_name.service"
echo "Started the Noctalia Drive Health collector."
;;
pause)
systemctl disable --now "$service_name.timer"
systemctl stop "$service_name.service"
echo "Paused the Noctalia Drive Health collector."
;;
esac