Add go-winres integration to embed legitimate PE resource metadata (company name,
product name, version, file description, copyright, and application manifest) into
Windows binaries. AV heuristic engines check for PE metadata as a trust signal --
its absence is one of the triggers for Go binary false positives like Kaspersky
PDM:Trojan.Win32.Generic detection.
- Add cmd/bd/winres/ with PE version info config and app manifest
- Add scripts/gen-winres.sh to generate .syso resource files
- Update .goreleaser.yml before hooks to run gen-winres at build time
- Update release.yml CI to install go-winres
- Update version bump script to include winres metadata
- Update ANTIVIRUS.md documentation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
New sync branches are created as orphan by default - no shared history
with main, creating a clean "data sync channel" for beads.
Changes:
- New branches: Created as orphan via `git checkout --orphan`
- Existing branches: Preserved as-is for backward compatibility
- Migration: `--orphan` flag deletes and recreates existing branch
- Safety check: Warns if --orphan would lose unpushed commits
Why orphan branches:
- Clean mental model (data-only branch, no code)
- No accidental merge risk (git warns about unrelated histories)
- Smaller repository footprint
Addresses GH#1004 Phase 1 and GH#1125.
- Makefile: Explicitly set CGO_ENABLED=1 for Dolt backend support
- DOLT.md: Update environment variable documentation to reflect
current server mode settings (BEADS_DOLT_* vars)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Executed-By: beads/crew/emma
Rig: beads
Role: crew
Document the --claim flag for bd update in both README.md and
CLI_REFERENCE.md. This atomic operation prevents race conditions
when multiple agents try to claim the same task from bd ready.
The --claim flag:
- Sets assignee to current user
- Sets status to in_progress
- Uses compare-and-swap semantics (fails if already claimed)
Also noted that bd stale can find abandoned claims.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add cross-platform desktop application (macOS, Windows, Linux) for
managing Beads issues with visual interface. Unique features include
multi-project support with favorites, image attachments, dashboard
with statistics, and advanced filtering.
Co-authored-by: Claude Code <noreply@anthropic.com>
BREAKING: bd set/get/clear are now bd kv set/get/clear
- Remove top-level set, get, clear commands
- All KV operations now under 'bd kv' namespace
- Add doctor check for KV sync status (warns in git-portable mode)
- Update CLI_REFERENCE.md documentation
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Executed-By: beads/crew/emma
Rig: beads
Role: crew
- Add Key-Value Store section to CLI_REFERENCE.md
- Add kv_test.go with comprehensive test coverage
- Tests cover: set, get, delete, list, special characters
Follow-up to PR #1164.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Executed-By: beads/crew/emma
Rig: beads
Role: crew
* fix(export): populate export_hashes after successful export (GH#1278)
Child issues created with --parent were missing from export_hashes table,
which affects integrity tracking and future incremental export features.
This fix ensures SetExportHash() is called for all exported issues:
- Updated ExportResult to include IssueContentHashes map
- Updated finalizeExport() to call SetExportHash() for each exported issue
- Updated exportToJSONLDeferred() to collect content hashes during export
- Updated performIncrementalExport() to collect content hashes for dirty issues
- Updated exportToJSONLWithStore() to call SetExportHash() after export
- Updated daemon's handleExport() to call SetExportHash() after export
Added test TestExportPopulatesExportHashes to verify the fix works for
both regular and hierarchical (child) issue IDs.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* docs: add GitHub Copilot integration guide
Add comprehensive documentation for using beads with GitHub Copilot in VS Code via the MCP server.
New files:
- docs/COPILOT_INTEGRATION.md - Complete setup guide with prerequisites, MCP tools reference, example workflows, troubleshooting, and FAQ
- website/docs/integrations/github-copilot.md - Shorter website version
Updated files:
- docs/INSTALLING.md - Added GitHub Copilot row to setup matrix and new "GitHub Copilot (VS Code)" section with quick setup steps
- website/docs/getting-started/ide-setup.md - Added GitHub Copilot section
- website/docs/integrations/mcp-server.md - Added VS Code / GitHub Copilot configuration examples for both .vscode/mcp.json and settings.json
Key clarifications:
- Beads is a system-wide CLI tool installed once, not cloned into projects
- The .beads/ directory only contains the issue database
- Added FAQ addressing "Do I need to clone beads?" explicitly
Fixes#148
* docs: add cross-platform paths for user-level VS Code MCP config
Add Linux and Windows paths alongside macOS for the VS Code
user-level MCP configuration. Users can now find the correct
path for their platform in a simple table format.
Paths by platform:
- macOS: ~/Library/Application Support/Code/User/mcp.json
- Linux: ~/.config/Code/User/mcp.json
- Windows: %APPDATA%\Code\User\mcp.json
Fixes#148
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
When issues have blocking dependencies, bd list now shows them inline:
- "(blocked by: X, Y)" when the issue depends on other issues
- "(blocks: A, B)" when other issues depend on this issue
This makes dependencies unmissable when reviewing epic subtasks, addressing
a recurring agent problem where reviewers miss dependencies because they
don't run bd show on each issue.
Example output:
○ bd-123 [P1] [task] - Design API (blocks: bd-124, bd-125)
○ bd-124 [P1] [task] - Implement (blocked by: bd-123, blocks: bd-125)
○ bd-125 [P1] [task] - Test (blocked by: bd-123, bd-124)
Only blocking dependencies (blocks, parent-child, conditional-blocks,
waits-for) are shown, not soft relationships like related or discovered-from.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add detailed documentation for using Dolt as an alternative storage
backend to SQLite, including:
- Quick start guide with installation instructions
- Server mode vs embedded mode comparison
- Configuration options in metadata.json and config.yaml
- Migration guide from SQLite to Dolt
- AWS S3+DynamoDB remote sync setup
- Performance characteristics and benchmarks
- Troubleshooting common issues
This documentation complements the recently added Dolt test suite
and helps users adopt the Dolt backend for their workflows.
Co-authored-by: upstream_syncer <matthew.baker@pihealth.ai>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Add complete documentation for Dolt backend covering:
- Migration from SQLite to Dolt
- Contributor onboarding (bootstrap on clone)
- Troubleshooting common issues
- Recovery procedures
- Server mode setup and management
- Git hooks integration
- Configuration reference
Also improve server mode error handling to suggest gt dolt start
when connection is refused.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat: update to use core tap for beads installation
Signed-off-by: Rui Chen <rui@chenrui.dev>
* remove custom tap related code and refs
Signed-off-by: Rui Chen <rui@chenrui.dev>
---------
Signed-off-by: Rui Chen <rui@chenrui.dev>
* fix(sync): read sync.mode from yaml first, then database
bd config set sync.mode writes to config.yaml (because sync.* is a
yaml-only prefix), but GetSyncMode() only read from the database.
This caused dolt-native mode to be ignored - JSONL export still
happened because the database had no sync.mode value.
Now GetSyncMode() checks config.yaml first (via config.GetSyncMode()),
falling back to database for backward compatibility.
Fixes: oss-5ca279
* fix(init): respect BEADS_DIR environment variable
Problem:
- `bd init` ignored BEADS_DIR when checking for existing data
- `bd init` created database at CWD/.beads instead of BEADS_DIR
- Contributor wizard used ~/.beads-planning as default, ignoring BEADS_DIR
Solution:
- Add BEADS_DIR check in checkExistingBeadsData() (matches FindBeadsDir pattern)
- Compute beadsDirForInit early, before initDBPath determination
- Use BEADS_DIR as default in contributor wizard when set
- Preserve precedence: --db > BEADS_DB > BEADS_DIR > default
Impact:
- Users with BEADS_DIR set now get consistent behavior across all bd commands
- ACF-style fork tracking (external .beads directory) now works correctly
Fixes: steveyegge/beads#???
* fix(doctor): respect BEADS_DIR environment variable
Also updates documentation to reflect BEADS_DIR support in init and doctor.
Changes:
- doctor.go: Check BEADS_DIR before falling back to CWD
- doctor_test.go: Add tests for BEADS_DIR path resolution
- WORKTREES.md: Document simplified BEADS_DIR+init workflow
- CONTRIBUTOR_NAMESPACE_ISOLATION.md: Note init/doctor BEADS_DIR support
* test(init): add BEADS_DB > BEADS_DIR precedence test
Verifies that BEADS_DB env var takes precedence over BEADS_DIR
when both are set, ensuring the documented precedence order:
--db > BEADS_DB > BEADS_DIR > default
* chore: fill in GH#1277 placeholder in sync_mode comment
Adds Dolt auto-commit functionality for write commands and sets explicit commit authors.
Includes fix for race condition in commandDidWrite (converted to atomic.Bool).
Original PR: #1267 by @coffeegoddd
Co-authored-by: Dustin Brown <dustin@dolthub.com>
Web UIs:
- beads-kanban-ui: Visual Kanban board with git branch status tracking,
epic/subtask management, design doc viewer, and activity timeline.
Claude Code Orchestration (new section):
- beads-orchestration: Multi-agent orchestration skill for Claude Code.
Orchestrator investigates issues, manages tasks automatically, and
delegates to tech-specific supervisors on isolated branches.
fix(daemon): prevent zombie state after database file replacement
Adds checkFreshness() to health check paths (GetMetadata, GetConfig, GetAllConfig) and refactors reconnect() to validate new connection before closing old.
PR-URL: https://github.com/steveyegge/beads/pull/1213
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* fix(routing): auto-enable hydration and flush JSONL after routed create
Fixes split-brain bug where issues routed to different repos (via routing.mode=auto)
weren't visible in bd list because JSONL wasn't updated and hydration wasn't configured.
**Problem**: When routing.mode=auto routes issues to a separate repo (e.g., ~/.beads-planning),
those issues don't appear in 'bd list' because:
1. Target repo's JSONL isn't flushed after create
2. Multi-repo hydration (repos.additional) not configured automatically
3. No doctor warnings about the misconfiguration
**Changes**:
1. **Auto-flush JSONL after routed create** (cmd/bd/create.go)
- After routing issue to target repo, immediately flush to JSONL
- Tries target daemon's export RPC first (if daemon running)
- Falls back to direct JSONL export if no daemon
- Ensures hydration can read the new issue immediately
2. **Enable hydration in bd init --contributor** (cmd/bd/init_contributor.go)
- Wizard now automatically adds planning repo to repos.additional
- Users no longer need to manually run 'bd repo add'
- Routed issues appear in bd list immediately after setup
3. **Add doctor check for hydrated repo daemons** (cmd/bd/doctor/daemon.go)
- New CheckHydratedRepoDaemons() warns if daemons not running
- Without daemons, JSONL becomes stale and hydration breaks
- Suggests: cd <repo> && bd daemon start --local
4. **Add doctor check for routing+hydration mismatch** (cmd/bd/doctor/config_values.go)
- Validates routing targets are in repos.additional
- Catches split-brain configuration before users encounter it
- Suggests: bd repo add <routing-target>
**Testing**: Builds successfully. Unit/integration tests pending.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* test(routing): add comprehensive tests for routing fixes
Add unit tests for all 4 routing/hydration fixes:
1. **create_routing_flush_test.go** - Test JSONL flush after routing
- TestFlushRoutedRepo_DirectExport: Verify direct JSONL export
- TestPerformAtomicExport: Test atomic file operations
- TestFlushRoutedRepo_PathExpansion: Test path handling
- TestRoutingWithHydrationIntegration: E2E routing+hydration test
2. **daemon_test.go** - Test hydrated repo daemon check
- TestCheckHydratedRepoDaemons: Test with/without daemons running
- Covers no repos, daemons running, daemons missing scenarios
3. **config_values_test.go** - Test routing+hydration validation
- Test routing without hydration (should warn)
- Test routing with correct hydration (should pass)
- Test routing target not in hydration list (should warn)
- Test maintainer="." edge case (should pass)
All tests follow existing patterns and use t.TempDir() for isolation.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* fix(tests): fix test failures and refine routing validation logic
Fixes test failures and improves validation accuracy:
1. **Fix routing+hydration validation** (config_values.go)
- Exclude "." from hasRoutingTargets check (current repo doesn't need hydration)
- Prevents false warnings when maintainer="." or contributor="."
2. **Fix test ID generation** (create_routing_flush_test.go)
- Use auto-generated IDs instead of hard-coded "beads-test1"
- Respects test store prefix configuration (test-)
- Fixed json.NewDecoder usage (file handle, not os.Open result)
3. **Fix config validation tests** (config_values_test.go)
- Create actual directories for routing paths to pass path validation
- Tests now verify both routing+hydration AND path existence checks
4. **Fix daemon test expectations** (daemon_test.go)
- When database unavailable, check returns "No additional repos" not error
- This is correct behavior (graceful degradation)
All tests now pass:
- TestFlushRoutedRepo* (3 tests)
- TestPerformAtomicExport
- TestCheckHydratedRepoDaemons (3 subtests)
- TestCheckConfigValues routing tests (5 subtests)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* docs: clarify when git config beads.role maintainer is needed
Clarify that maintainer role config is only needed in edge case:
- Using GitHub HTTPS URL without credentials
- But you have write access (are a maintainer)
In most cases, beads auto-detects correctly via:
- SSH URLs (git@github.com:owner/repo.git)
- HTTPS with credentials
This prevents confusion - users with SSH or credential-based HTTPS
don't need to manually configure their role.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* fix(lint): address linter warnings in routing flush code
- Add missing sqlite import in daemon.go
- Fix unchecked client.Close() error return
- Fix unchecked tempFile.Close() error returns
- Mark unused parameters with _ prefix
- Add nolint:gosec for safe tempPath construction
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Roland Tritsch <roland@ailtir.com>
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
Inspired by PR #1164 from Piyush Jha (@Hackinet). Groups commands
under 'bd kv' subcommand for cleaner namespacing.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix(orphans): honor --db flag for cross-repo orphan detection
Problem:
- `bd orphans --db /path` ignored the --db flag entirely
- FindOrphanedIssues() hardcoded local .beads/ directory
Solution:
- Introduce IssueProvider interface for abstract issue lookup
- Add StorageProvider adapter wrapping Storage instances
- Update FindOrphanedIssues to accept provider instead of path
- Wire orphans command to create provider from --db flag
Closes: steveyegge/beads#1196
* test(orphans): add cross-repo and provider tests for --db flag fix
- Add TestFindOrphanedIssues_WithMockProvider (table-driven, UT-01 through UT-09)
- Add TestFindOrphanedIssues_CrossRepo (validates --db flag honored)
- Add TestFindOrphanedIssues_LocalProvider (backward compat RT-01)
- Add TestFindOrphanedIssues_ProviderError (error handling UT-07)
- Add TestFindOrphanedIssues_IntegrationCrossRepo (IT-02 full)
- Add TestLocalProvider_* unit tests
Coverage for IssueProvider interface and cross-repo orphan detection.
* docs: add bd orphans command to CLI reference
Document the orphan detection command including the cross-repo
workflow enabled by the --db flag fix in this PR.
- Prioritize beads.role git configuration in detection logic
- Add validation checks to bd doctor for role setup
- Update documentation with migration guides and setup steps
- Include unit tests for role validation logic
Allows users to explicitly define their development role for more predictable routing and diagnostics.
Change routing.mode default from "auto" to "" (empty/disabled).
This fixes GH#1165 where fresh `bd init --prefix X` followed by
`bd create` would unexpectedly route to ~/.beads-planning and fail
with "database not initialized: issue_prefix config is missing".
Auto-routing now requires explicit opt-in via:
- `bd init --contributor` flag, OR
- `bd config set routing.mode auto`
Includes test verifying the default and doc updates clarifying
the opt-in requirement.
* fix(config): validate sync-branch at config time
Add sync-branch validation to validateYamlConfigValue() to reject
main/master at config time, preventing the validation bypass in GH#1166.
- Add case for sync-branch and sync.branch keys
- Inline validation logic to avoid import cycle (config <-> syncbranch)
- Add unit tests for rejection (main/master) and acceptance (valid names)
Part of: #1166
* fix(sync): add runtime guard for sync-branch == current-branch
Add dynamic runtime check before worktree operations to catch cases
where sync-branch matches the current branch. This provides defense
in depth for manual YAML edits, pre-fix configs, or non-main/master
branch names (trunk, develop, production, etc.).
- Check IsSyncBranchSameAsCurrent() after hasSyncBranchConfig is set
- Position check BEFORE worktree entry (CWD changes inside worktree)
- Add integration test TestSync_FailsWhenOnSyncBranch
Part of: #1166
* docs: note main/master restriction in sync-branch FAQ
Clarifies that git worktrees cannot checkout the same branch in
multiple locations, so main/master cannot be used as sync branch.
Centralizes repository context resolution via RepoContext API, fixing bugs where git commands run in the wrong repo when BEADS_DIR points elsewhere or in worktree scenarios.
Update all documentation to use the new subcommand syntax:
- `bd daemon --start` → `bd daemon start`
- `bd daemon --stop` → `bd daemon stop`
- `bd daemon --status` → `bd daemon status`
- `bd daemon --health` → `bd daemon status --all`
- `--global=false` → `--local`
The old flag syntax is deprecated but still works with warnings.
Closes: bd-734vd
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add deprecation notice explaining:
- SQLite → Dolt migration removes custom table support
- External integrations should use standalone sync tools
- Point to jira-beads-sync as the model
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>