Root cause: multiple code paths in bd init could skip setting beads.role: - BEADS_DIR set → git init skipped → isGitRepo() false → role block skipped - promptContributorMode() fails → role never set - Non-interactive without explicit --role → only sets if not already present Fix: Add safety net at end of init that checks isGitRepo() && !hasRole and defaults to 'maintainer' (or --role value). This guarantees every init leaves beads.role configured. Also: - Improve routing.go warning to show one-command fix - Update doctor check fix to use 'git config' directly (simpler) - Add TestInitNonInteractiveAlwaysSetsRole regression test Amp-Thread-ID: https://ampcode.com/threads/T-019d4a99-63c8-779f-bb8e-ee8522b61cdf Co-authored-by: Amp <amp@ampcode.com> |
||
|---|---|---|
| .. | ||
| routing.go | ||
| routing_test.go | ||