feat: auto-protect forks from committing upstream issue database

When bd detects it's running in a fork (origin != steveyegge/beads),
automatically add .beads/issues.jsonl to .git/info/exclude.

This prevents contributors from accidentally including issue database
changes in their PRs. The exclusion is:
- Per-clone (doesn't modify tracked files
- One-time setup (checks if already excluded)
- Silent (only logs in debug mode)

Maintainers (origin = steveyegge/beads) are not affected.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
EOF
)
This commit is contained in:
Steve Yegge
2025-12-18 18:56:59 -08:00
parent efdfbac504
commit f7c746adb9
3 changed files with 215 additions and 0 deletions

View File

@@ -195,6 +195,9 @@ var rootCmd = &cobra.Command{
actor = config.GetString("actor")
}
// Protect forks from accidentally committing upstream issue database
ensureForkProtection()
// Performance profiling setup
// When --profile is enabled, force direct mode to capture actual database operations
// rather than just RPC serialization/network overhead. This gives accurate profiles