feat: muse maintenance — scheduled store maintenance orchestration
Implements muse maintenance with three subcommands:
maintenance run [--task gc|verify-objects] [--all] [--dry-run] [--json] Executes selected tasks; persists last-run timestamps to .muse/maintenance.json. --dry-run previews without mutations.
maintenance status [--json] Shows schedule config (enabled, period_hours) and per-task last-run timestamps.
maintenance schedule [--period-hours N] [--enable] [--disable] Updates .muse/maintenance.json schedule configuration.
Tasks: gc — run_gc(full=True); removes unreachable objects, commits, and snapshots from the store. verify-objects — rehashes every object file; reports checked/failed.
JSON output for run: {tasks_run, results: {gc: {...}, verify-objects: {...}}, dry_run, elapsed_seconds}
- muse/cli/commands/maintenance.py: full implementation - muse/cli/app.py: maintenance registered as maintenance - tests/test_cmd_maintenance.py: 25 tests covering run/status/schedule, dry-run semantics, JSON schema, corrupt-object detection, 100-object stress
Closes #15
0 comments
muse hub commit comment sha256:c67667c855a952b2c715c746eae439ea8824ba48aa3c9d1bb8f3e408576a2c3d --body "your comment"
No comments yet. Be the first to start the discussion.