aboutsummaryrefslogtreecommitdiffstats
path: root/lib/data.lua
AgeCommit message (Collapse)AuthorFilesLines
2026-09-17feat: parse df and du output for the disk and cache cardsDanilo M.1-0/+76
2026-09-17feat: add per-core CPU times and named sensor readsDanilo M.1-0/+53
2026-09-16feat: add stateful CPU percentage counterDanilo M.1-0/+27
Load is a delta, so one reading cannot yield a percentage. The first call returns nil rather than a fabricated number: 100% on startup reads as a real spike. A non-advancing counter also returns nil instead of dividing by zero, and the result is clamped because a suspend/resume can produce a nonsense delta. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-16feat: add /proc and /sys parsers with fixture testsDanilo M.1-0/+75
Parsers take file contents as a string, not a path, so they test against committed fixtures with no filesystem mocking. hwmon is globbed by its name file rather than a fixed index, carried over from the old config: indices drift across kernel reorders and a stale one silently reads a different chip. Failure returns nil, never 0. A sensor reading 0 C is legitimate, so 0 cannot double as an error value. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>