ci: NO-JIRA add doc cleanup tools, sync enforcer, and edit tracker hooks#1125
ci: NO-JIRA add doc cleanup tools, sync enforcer, and edit tracker hooks#1125belumontoya merged 4 commits intostagingfrom
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fb8b532e9a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
|
Ignacio Ropolo (@iropolo) here is the doc tools automation 😉 |
…, fix stash+push detection
|
Claude (@claude) review this PR |
|
Claude finished belumontoya's task in 1m 53s —— View job PR Review —
|
- Fix Skill(doc-janitor) → Agent(doc-janitor) in settings.json permissions - Allow clean PR creation through without deny (pr-fill already suggests janitor) - Add set -e to pre-push-pr-guard.sh for consistent error handling - Fix UUOC: cat|cut → cut < file - Change log separator from : to tab to avoid mangling paths with colons
🛠️ Type Of Change
📖 Jira Ticket
N/A
📖 Description
Adds documentation cleanup and sync tooling for the Dialtone monorepo — a CI workflow, two Claude Code hooks, two commands, one agent, and one skill. These tools keep
packages/dialtone-docs/src/content/in sync with source code changes automatically.CI Workflow
cleanup-plan-docs.yml— auto-deletesPLAN-*.mdanddocs/plans/after a PR merges to stagingHooks
post-tool-use-tracker.sh(PostToolUse on Edit/Write) — silently logs every file edit to.claude/tsc-cache/<session>/, tracks affected packages and their NX build/test commandspre-push-pr-guard.sh(PreToolUse on Bash) — fires ongit pushorgh pr create, reads the edit log, maps source packages todialtone-docscontent files, denies push if docs are missing and triggers the doc-sync-enforcer. Clean sessions pass through without interruption.Skills/Agents/Commands
doc-sync-enforcerskill +/doc-sync-enforcercommand — reads source code changes, maps them topackages/dialtone-docs/src/content/files, updates the docs to reflect what changeddoc-janitoragent +/doc-janitorcommand — sweeps stale artifacts (session files, backups, done plans) before mergingConfig
.claude/settings.json— wired both hooks, addedSkill(doc-sync-enforcer)andAgent(doc-janitor)to permissions allow list.gitignore— added work artifact patterns (PLAN-*.md,SESSION_*.md,*.backup, etc.) and.claude/tsc-cache/pr-fill.md— added step to suggest/doc-janitorduring PR creation (non-blocking)CLAUDE.md— added Doc Sync Tooling section with package→doc mapping and session cache docsFlow
💡 Context
Dialtone is getting a new
dialtone-docspackage (PR #1051) with AI-discoverable documentation. This tooling ensures those docs stay in sync with source code changes automatically — the hooks detect gaps and the enforcer fixes them before code is pushed.📝 Checklist
🔮 Next Steps