Public Access
feat(workflow-sync): add --phase health drift detection + --repo-filter [#350] #358
Reference in New Issue
Block a user
Delete Branch "feature/workflow-health-check"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Adds
workflow_sync.php --phase health— read-only drift detection that flags any governed repo missing its synced.mokogit/workflows/, exits non-zero for CI, and optionally sends a critical ntfy push (--alert-ntfy) and/or opens a Git issue on the affected repo (--alert-issue, idempotent). Also adds--repo-filterto scope sync/health to specific repos, and registersworkflow:syncinbin/moko.This is the one genuinely-unique piece of the superseded PR #356 (against a stale dev base) — everything else in #356 (the MokoGitea→MokoGit rebrand, manifest→metadata-API retirement, npm/dot template maps, schema markers, CI fixes) already landed on
mainvia #317–#355, so #356 was closed rather than merged.Design
PLATFORM_TEMPLATES) minusPLATFORM_EXCLUDES— same source of truth the sync writes from, so the check can't pass while the sync is broken.evaluateRepoHealth(); branch-existence guard skips repos lacking the target branch.Verification
php -lclean; ran--phase health --repo-filter .mokogit,.vault,.mokogit-private→ correctly reports all healthy.[Unreleased]updated (Validate PR gate).https://claude.ai/code/session_014Fjb4NvgviMoNU6NrGa4VE