feat(doctor): add redirect configuration health checks
Add three new bd doctor checks for redirect configuration health: 1. CheckRedirectTargetValid - Verifies redirect target exists and contains a valid beads database 2. CheckRedirectTargetSyncWorktree - Verifies redirect target has beads-sync worktree when using sync-branch mode 3. CheckNoVestigialSyncWorktrees - Detects unused .beads-sync worktrees in redirected repos that waste space These checks help diagnose redirect configuration issues in multi-clone setups like Gas Town polecats and crew workspaces. Closes bd-b88x3 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -450,6 +450,21 @@ func runDiagnostics(path string) doctorResult {
|
||||
result.Checks = append(result.Checks, redirectTrackingCheck)
|
||||
// Don't fail overall check for redirect tracking, just warn
|
||||
|
||||
// Check 14c: redirect target validity (target exists and has valid db)
|
||||
redirectTargetCheck := convertWithCategory(doctor.CheckRedirectTargetValid(), doctor.CategoryGit)
|
||||
result.Checks = append(result.Checks, redirectTargetCheck)
|
||||
// Don't fail overall check for redirect target, just warn
|
||||
|
||||
// Check 14d: redirect target sync worktree (target has beads-sync if needed)
|
||||
redirectTargetSyncCheck := convertWithCategory(doctor.CheckRedirectTargetSyncWorktree(), doctor.CategoryGit)
|
||||
result.Checks = append(result.Checks, redirectTargetSyncCheck)
|
||||
// Don't fail overall check for redirect target sync, just warn
|
||||
|
||||
// Check 14e: vestigial sync worktrees (unused worktrees in redirected repos)
|
||||
vestigialWorktreesCheck := convertWithCategory(doctor.CheckNoVestigialSyncWorktrees(), doctor.CategoryGit)
|
||||
result.Checks = append(result.Checks, vestigialWorktreesCheck)
|
||||
// Don't fail overall check for vestigial worktrees, just warn
|
||||
|
||||
// Check 15: Git merge driver configuration
|
||||
mergeDriverCheck := convertWithCategory(doctor.CheckMergeDriver(path), doctor.CategoryGit)
|
||||
result.Checks = append(result.Checks, mergeDriverCheck)
|
||||
|
||||
Reference in New Issue
Block a user