Run bd doctor at end of bd init to verify setup
Implements bd-zwtq: After bd init completes, run doctor diagnostics to catch configuration problems before user encounters them in normal workflow. If any warnings or errors are detected, show a summary with issue names and messages, then direct user to run 'bd doctor --fix'. This helps users immediately identify and fix setup issues like: - Missing git hooks - Unconfigured merge driver - Missing agent documentation - Metadata tracking not initialized 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -396,6 +396,27 @@ With --no-db: creates .beads/ directory and issues.jsonl file instead of SQLite
|
||||
}
|
||||
|
||||
fmt.Printf("Run %s to get started.\n\n", cyan("bd quickstart"))
|
||||
|
||||
// Run bd doctor diagnostics to catch setup issues early (bd-zwtq)
|
||||
doctorResult := runDiagnostics(cwd)
|
||||
// Check if there are any warnings or errors (not just critical failures)
|
||||
hasIssues := false
|
||||
for _, check := range doctorResult.Checks {
|
||||
if check.Status != statusOK {
|
||||
hasIssues = true
|
||||
break
|
||||
}
|
||||
}
|
||||
if hasIssues {
|
||||
fmt.Printf("%s Setup incomplete. Some issues were detected:\n", yellow("⚠"))
|
||||
// Show just the warnings/errors, not all checks
|
||||
for _, check := range doctorResult.Checks {
|
||||
if check.Status != statusOK {
|
||||
fmt.Printf(" • %s: %s\n", check.Name, check.Message)
|
||||
}
|
||||
}
|
||||
fmt.Printf("\nRun %s to see details and fix these issues.\n\n", cyan("bd doctor --fix"))
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user