Commit Graph

4036 Commits

Author SHA1 Message Date
Steve Yegge
f2b7925dee chore: sync beads changes 2025-12-14 17:21:10 -08:00
Steve Yegge
03e7d7c650 feat: support claude.local.md for local-only documentation
Add support for claude.local.md and .claude/claude.local.md as local-only
alternatives to CLAUDE.md. These files are intended to be gitignored for
personal customizations that should not be committed to the repo.

Changes:
- Update CheckAgentDocumentation to detect claude.local.md files
- Update CheckLegacyBeadsSlashCommands to check claude.local.md files
- Update CheckDocumentationBdPrimeReference to check claude.local.md files
- Add fix message mentioning claude.local.md as an option
- Add test cases for claude.local.md support

Closes #488

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:59 -08:00
Steve Yegge
79aa949681 chore: sync beads 2025-12-14 17:20:49 -08:00
Steve Yegge
17389d0eb4 fix(sync): handle sync.branch == current branch (GH#519)
When sync.branch is configured to the same branch as the current branch,
git worktree creation fails because the same branch cannot be checked out
in multiple locations.

This fix detects when sync.branch equals the current branch and falls back
to direct commits on the current branch instead of using the worktree-based
approach.

Changes:
- Add IsSyncBranchSameAsCurrent() helper in syncbranch package
- Add GetCurrentBranch() helper function
- Update sync.go to detect this case and skip worktree operations
- Add unit tests for the new functionality

Closes #519

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:47 -08:00
Steve Yegge
69d14e21d8 fix(git): find .beads from nested worktrees (GH#509)
When worktrees are nested under the main repo (e.g.,
/project/.worktrees/feature/), bd now correctly finds .beads/ in the
parent repo.

The fix simplifies GetMainRepoRoot() to use `git rev-parse --git-common-dir`
which always returns the main repo's .git directory, regardless of whether
we're in a regular repo, a worktree, or a nested worktree.

- Simplified GetMainRepoRoot() implementation
- Added tests for nested worktree scenarios
- Updated CHANGELOG.md

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:46 -08:00
Steve Yegge
8e1a841daa feat(init): auto-add 'landing the plane' instructions to AGENTS.md
Closes GH#516: bd init now automatically:
- Creates AGENTS.md and @AGENTS.md with landing-the-plane instructions if they don't exist
- Appends the instructions to existing files if they don't have them
- Skips if the section already exists (idempotent)
- Skips in stealth mode (user wants invisible setup)

The landing-the-plane instructions ensure AI agents properly complete
their work sessions by pushing all changes to remote before ending.
2025-12-14 17:20:43 -08:00
Steve Yegge
214b5f9d07 fix(hooks): pre-commit hook warns instead of failing on flush error
Fixes GH#483 - The pre-commit hook was blocking commits when
`bd sync --flush-only` failed, even if the user had removed beads
from their branch. This made it impossible to commit on branches
that don't have beads configured.

Changes:
- Change "Error:" to "Warning:" in the message
- Remove `exit 1` so commits proceed even if flush fails
- Add comments explaining why we don't block commits

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:29 -08:00
Steve Yegge
424b0aa68a chore: sync beads changes 2025-12-14 17:20:24 -08:00
Steve Yegge
56fe3f78c2 chore: remove foreign prefix entries from deletions.jsonl (again) 2025-12-14 17:20:18 -08:00
Steve Yegge
344fc1b95d docs: explain sync-branch worktree behavior (GH#510)
Add comprehensive documentation about beads-created worktrees:
- New section in WORKTREES.md explaining why and where beads creates worktrees
- Common confusion: 'beads took over main!' with solution
- Troubleshooting entries for 'branch already checked out' errors
- FAQ entry: 'Why did beads create worktrees in my .git directory?'

This addresses user confusion when beads' sync-branch feature creates
internal worktrees that can lock branches users want to checkout.

Closes #510

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:12 -08:00
Steve Yegge
80e56d58f3 docs: document bd setup command
Add comprehensive documentation for the `bd setup` command:

- New docs/SETUP.md with full documentation for all three integrations:
  - Claude Code (hooks for SessionStart/PreCompact)
  - Cursor IDE (rules file in .cursor/rules/)
  - Aider (config file with human-in-the-loop workflow)

- Updated docs/CLI_REFERENCE.md:
  - Added Setup & Integration section
  - Added SETUP.md to See Also links
  - Added to Quick Navigation

Closes #518

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:10 -08:00
Steve Yegge
c247d18115 chore: regenerate BD_GUIDE.md with v0.29.0
Update from v0.24.2 to v0.29.0 to get the generic template content
(removes beads-specific Go/SQLite/Cobra content).

Relates to: GH#497

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:20:05 -08:00
Steve Yegge
50608ce3a5 chore: close bd-6xfz (GH#517 fix) 2025-12-14 17:19:46 -08:00
Steve Yegge
76568e8802 fix(prime): document priority format to prevent Claude using 'medium'
GH#517: Claude uses 'medium' instead of P2/2 for priority, causing
infinite error loops. The bd prime output didn't show the --priority
flag or explain the valid format.

Fix: Add --priority=2 to the create example and add a clear note
explaining that priority must be 0-4 or P0-P4, NOT 'high/medium/low'.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 17:19:06 -08:00
Steve Yegge
b98b25792e chore: remove foreign prefix entries from deletions manifest
These entries (beads-, test-, webui-, worker2-) were hydrated from git
history but don't belong in this repo's bd- namespace. They were causing
import failures during beads sync due to prefix mismatch validation.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 16:58:14 -08:00
Steve Yegge
c21c8cb77b fix: resolve beads sync issues - remove foreign prefixes from deletions.jsonl 2025-12-14 16:56:12 -08:00
Steve Yegge
8d409fc719 chore: sync beads 2025-12-14 16:55:37 -08:00
Steve Yegge
1b5efd5d47 chore: sync beads state 2025-12-14 16:55:07 -08:00
Steve Yegge
0e70c813c7 chore: bd sync complete 2025-12-14 16:54:53 -08:00
Steve Yegge
59e9664284 chore: finalize beads sync state 2025-12-14 16:54:34 -08:00
Steve Yegge
cfb9b3f6b1 chore: final beads sync 2025-12-14 16:54:32 -08:00
Steve Yegge
b0b4e9fa44 bd sync: 2025-12-14 16:54:27 2025-12-14 16:54:27 -08:00
Steve Yegge
9d51f0579a bd sync: 2025-12-14 16:54:23 2025-12-14 16:54:23 -08:00
Steve Yegge
fc99ca0ca3 bd sync: merge divergent histories (6 local + 4 remote commits) 2025-12-14 16:54:12 -08:00
Steve Yegge
c678de0fea chore: clean beads state before sync 2025-12-14 16:54:05 -08:00
Steve Yegge
fbcc00ebac chore: sync beads flush 2025-12-14 16:54:00 -08:00
Steve Yegge
da753ea137 chore: final beads sync cleanup 2025-12-14 16:53:59 -08:00
Steve Yegge
659fbd0b59 chore: remove legacy deletions files and clean up beads 2025-12-14 16:53:51 -08:00
Steve Yegge
33627567f1 chore: force clean wrong-prefix entries 2025-12-14 16:53:32 -08:00
Steve Yegge
ce80664005 chore: sync beads deletions 2025-12-14 16:53:10 -08:00
Steve Yegge
ec280abd5e chore: final cleanup - remove orphan issues from DB export 2025-12-14 16:53:06 -08:00
Steve Yegge
cb70fec186 fix: clean beads state - sync database with JSONL 2025-12-14 16:53:01 -08:00
Steve Yegge
622b29d9a9 chore: sync beads changes 2025-12-14 16:52:32 -08:00
Steve Yegge
0aa05ab313 chore: final cleanup of wrong-prefixed deletions 2025-12-14 16:52:30 -08:00
Steve Yegge
ab20f6947a chore: update beads after sync cleanup 2025-12-14 16:52:18 -08:00
Steve Yegge
114ae4c269 chore: purge wrong-prefix entries from deletions.jsonl 2025-12-14 16:51:59 -08:00
Steve Yegge
880a4431c3 chore: fix db-jsonl count mismatch 2025-12-14 16:51:37 -08:00
Steve Yegge
0a4ba385e0 chore: sync beads - clean up prefix mismatch 2025-12-14 16:51:09 -08:00
Steve Yegge
29b3cde3c0 chore: remove wrong-prefixed entries from deletions.jsonl 2025-12-14 16:50:57 -08:00
Steve Yegge
509d96e58a chore: sync beads 2025-12-14 16:50:24 -08:00
Steve Yegge
94b7e4e52d chore: sync beads changes after sync branch fix 2025-12-14 16:49:57 -08:00
Steve Yegge
48697663d8 chore: clean up beads sync state 2025-12-14 16:49:25 -08:00
Steve Yegge
69ebb3edca chore: clean beads state after sync branch conflicts 2025-12-14 16:48:57 -08:00
Steve Yegge
80c9395ea3 chore: clean beads state 2025-12-14 16:48:49 -08:00
Steve Yegge
86bffcc9fe chore: sync beads after prefix cleanup 2025-12-14 16:47:47 -08:00
Steve Yegge
bdfbcb724a chore: flush beads changes 2025-12-14 16:46:49 -08:00
Steve Yegge
fb55272156 chore: clean beads - remove orphans and fix prefixes 2025-12-14 16:46:01 -08:00
Steve Yegge
3c8a09d92f chore: sync beads database and JSONL 2025-12-14 16:45:59 -08:00
Steve Yegge
ee8fe2bbb7 chore: sync sanitized issues.jsonl 2025-12-14 16:44:51 -08:00
Steve Yegge
8fa1361ef3 fix: remove wrong-prefix issues from sync branch 2025-12-14 16:44:43 -08:00