From 5f29e393a6696c6f1e5ef2394bddd58aab7f8eda Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Sun, 9 Nov 2025 08:24:03 -0500 Subject: Fix task auto-commit with pre-commit hook Implemented proper pre-commit hook that: - Calls 'task export --flush' to consolidate tasks - Auto-stages .tasks/tasks.jsonl if modified - Runs before every commit Added reminder message after 'task update' to inform users that task changes will be committed on next git commit. Updated AGENTS.md to document the auto-commit behavior. This fixes the bug where task status updates (e.g., marking tasks as Done) were not being committed to git. --- AGENTS.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'AGENTS.md') diff --git a/AGENTS.md b/AGENTS.md index 3cd9aa7..c07d8ed 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -88,6 +88,8 @@ task update t-20241108120000 in-progress task update t-20241108120000 done ``` +**Note**: Task updates modify `.tasks/tasks.jsonl` but don't auto-commit. The pre-commit hook will automatically export and stage task changes on your next `git commit`. + ### View Dependencies ```bash task deps -- cgit v1.2.3