Phase 0-2: Schema cleanup, typed relations, event-driven automation

- Phase 0: AGENTS.md cleanup (dedup quotes, renumber sections, merge qmd)
- Phase 1: typed relations (manage-relations.py, graph-search.py, check-staleness.py, detect-conflicts.py)
- Phase 2: frontmatter validator, weekly lint, knowledge promotion, git hooks
- Fix .gitignore to track tools/ and .githooks/
- Fix git remote URL (remove plaintext token)
- New wiki pages: 504 pages, 34 raw sources
This commit is contained in:
hehaiguang1123
2026-07-01 08:05:43 +08:00
parent e544d6e04a
commit a6f05ab2d5
1067 changed files with 522992 additions and 819 deletions
+5
View File
@@ -0,0 +1,5 @@
#!/bin/sh
# post-merge — git pull/merge 后自动更新 qmd 索引
echo "=== post-merge: Updating qmd index ==="
node "C:\Users\hhhh2024\AppData\Roaming\npm\node_modules\@tobilu\qmd\dist\cli\qmd.js" update 2>/dev/null || echo " qmd update skipped (not installed?)"
echo "=== Done ==="
+11
View File
@@ -0,0 +1,11 @@
#!/bin/sh
# pre-commit — 验证被修改的 wiki 页面 frontmatter
CHANGED=$(git diff --cached --name-only --diff-filter=ACM | grep '^wiki/.*\.md$')
if [ -z "$CHANGED" ]; then exit 0; fi
python tools/scripts/validate-frontmatter.py --git-hook
if [ $? -ne 0 ]; then
echo "ERROR: Frontmatter validation failed. Commit rejected."
echo "Run 'python tools/scripts/validate-frontmatter.py --files <file>' to check."
exit 1
fi