feat: add Git worktree compatibility (PR #478)
Adds comprehensive Git worktree support for beads issue tracking: Core changes: - New internal/git/gitdir.go package for worktree detection - GetGitDir() returns proper .git location (main repo, not worktree) - Updated all hooks to use git.GetGitDir() instead of local helper - BeadsDir() now prioritizes main repository's .beads directory Features: - Hooks auto-install in main repo when run from worktree - Shared .beads directory across all worktrees - Config option no-install-hooks to disable auto-install - New bd worktree subcommand for diagnostics Documentation: - New docs/WORKTREES.md with setup instructions - Updated CHANGELOG.md and AGENT_INSTRUCTIONS.md Testing: - Updated tests to use exported git.GetGitDir() - Added worktree detection tests Co-authored-by: Claude <noreply@anthropic.com> Closes: #478
This commit is contained in:
@@ -12,7 +12,7 @@ Use the beads MCP `init` tool with the prefix parameter (if provided) to set up
|
||||
After initialization:
|
||||
1. Show the database location
|
||||
2. Show the issue prefix that will be used
|
||||
3. Explain the basic workflow (or suggest running `/beads:workflow`)
|
||||
4. Suggest creating the first issue with `/beads:create`
|
||||
3. Explain the basic workflow (or suggest running `/bd-workflow`)
|
||||
4. Suggest creating the first issue with `/bd-create`
|
||||
|
||||
If beads is already initialized, inform the user and show project stats using the `stats` tool.
|
||||
|
||||
@@ -12,6 +12,6 @@ Use the beads MCP `stats` tool to retrieve project metrics and present them clea
|
||||
- Recently updated issues
|
||||
|
||||
Optionally suggest actions based on the stats:
|
||||
- High number of blocked issues? Run `/beads:blocked` to investigate
|
||||
- No in-progress work? Run `/beads:ready` to find tasks
|
||||
- Many open issues? Consider prioritizing with `/beads:update`
|
||||
- High number of blocked issues? Run `/bd-blocked` to investigate
|
||||
- No in-progress work? Run `/bd-ready` to find tasks
|
||||
- Many open issues? Consider prioritizing with `/bd-update`
|
||||
|
||||
@@ -9,11 +9,11 @@ Display the beads workflow for AI agents and developers.
|
||||
Beads is an issue tracker designed for AI-supervised coding workflows. Here's how to use it effectively:
|
||||
|
||||
## 1. Find Ready Work
|
||||
Use `/beads:ready` or the `ready` MCP tool to see tasks with no blockers.
|
||||
Use `/bd-ready` or the `ready` MCP tool to see tasks with no blockers.
|
||||
|
||||
## 2. Claim Your Task
|
||||
Update the issue status to `in_progress`:
|
||||
- Via command: `/beads:update <id> in_progress`
|
||||
- Via command: `/bd-update <id> in_progress`
|
||||
- Via MCP tool: `update` with `status: "in_progress"`
|
||||
|
||||
## 3. Work on It
|
||||
@@ -21,18 +21,18 @@ Implement, test, and document the feature or fix.
|
||||
|
||||
## 4. Discover New Work
|
||||
As you work, you'll often find bugs, TODOs, or related work:
|
||||
- Create issues: `/beads:create` or `create` MCP tool
|
||||
- Create issues: `/bd-create` or `create` MCP tool
|
||||
- Link them: Use `dep` MCP tool with `type: "discovered-from"`
|
||||
- This maintains context and work history
|
||||
|
||||
## 5. Complete the Task
|
||||
Close the issue when done:
|
||||
- Via command: `/beads:close <id> "Completed: <summary>"`
|
||||
- Via command: `/bd-close <id> "Completed: <summary>"`
|
||||
- Via MCP tool: `close` with reason
|
||||
|
||||
## 6. Check What's Unblocked
|
||||
After closing, check if other work became ready:
|
||||
- Use `/beads:ready` to see newly unblocked tasks
|
||||
- Use `/bd-ready` to see newly unblocked tasks
|
||||
- Start the cycle again
|
||||
|
||||
## Tips
|
||||
@@ -43,12 +43,12 @@ After closing, check if other work became ready:
|
||||
- **Git workflow**: After `git pull`, JSONL auto-imports if newer than DB
|
||||
|
||||
## Available Commands
|
||||
- `/beads:ready` - Find unblocked work
|
||||
- `/beads:create` - Create new issue
|
||||
- `/beads:show` - Show issue details
|
||||
- `/beads:update` - Update issue
|
||||
- `/beads:close` - Close issue
|
||||
- `/beads:workflow` - Show this guide (you are here!)
|
||||
- `/bd-ready` - Find unblocked work
|
||||
- `/bd-create` - Create new issue
|
||||
- `/bd-show` - Show issue details
|
||||
- `/bd-update` - Update issue
|
||||
- `/bd-close` - Close issue
|
||||
- `/bd-workflow` - Show this guide (you are here!)
|
||||
|
||||
## MCP Tools Available
|
||||
Use these via the beads MCP server:
|
||||
|
||||
Reference in New Issue
Block a user