The pre-commit hook has been updated to automatically convert JSON event files to Markdown format during commits.
When you commit JSON event files, the pre-commit hook will:
- Validate all staged event files (JSON and Markdown)
- Automatically convert any staged JSON files to Markdown
- Stage the generated Markdown files in the same commit
- Validate dates
- Test API generation
- No manual conversion needed: Just create events in JSON format and commit
- Automatic sync: JSON and Markdown formats stay in sync
- Seamless workflow: One less step in the research pipeline
The hook looks for any staged JSON files in timeline/data/events/*.json and:
- Runs
convert_to_markdown.pyon each JSON file - Automatically stages the generated
.mdfile - Reports how many files were converted
📝 Step 1.5/4: Auto-converting JSON events to Markdown...
✓ Converted 2025-11-05--example-event.json → 2025-11-05--example-event.md
✅ Auto-converted 1 JSON events to Markdown!The pre-commit hook is located at:
.git/hooks/pre-commit
This file is automatically used by git and does not need to be committed to the repository.
If you need to convert all JSON files manually:
python3 timeline/scripts/convert_to_markdown.py --allLast updated: November 11, 2025