Commit graph

19 commits

Author SHA1 Message Date
Julian Palmerio
25703f8635
feat: add Copilot CLI setup recipe (#3839)
Adds `bd setup copilot` as a recipe-driven integration that installs a native Copilot CLI plugin manifest (.copilot-plugin/plugin.json) with SessionStart/PreCompact hooks and repository instructions (.github/copilot-instructions.md).

Co-authored-by: Julian Palmerio <julianpalmerio@hotmail.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-05-14 10:51:38 -07:00
matt wilkie
0c47b3c5ac
fix(init): use git origin as default Dolt remote (#3909)
* fix(init): wire git origin as Dolt remote

Default bd init now treats a git origin as the Dolt remote, persists sync.remote, and still skips synthesis in --stealth. JSONL auto-export/import paths now warn or skip based on sync.remote so exports do not masquerade as cross-machine sync.

Docs and generated agent/CLI references now state that Dolt is canonical, refs/dolt/data is the sync channel, and .beads/issues.jsonl is export/interchange/backup only.

_codex-gpt-5-xhigh on behalf of maphew_

* test: keep embedded command stderr out of parsed stdout

Embedded command tests parse IDs and JSON from command output. The new auto-export warnings correctly go to stderr, but several tests used CombinedOutput and treated warnings as stdout, which broke CI shards that parse issue IDs or JSON lists. Capture stdout separately on success while preserving combined output for error diagnostics.\n\n_codex-gpt-5-medium on behalf of CI Bot_

---------

Co-authored-by: CI Bot <ci@beads.test>
2026-05-13 07:02:39 -07:00
matt wilkie
ec116c46f5
Consolidate docs evidence review inventory
Complete mybd-pnm docs evidence review.\n\n- Add verified docs disposition inventory and canonical seams.\n- Stage stale duplicate docs under docs/staged-for-removal with a manifest.\n- Refresh generated CLI docs and harden the generator for CRLF/stdin handling.\n\nFollow-up: mybd-xfr for automated docs freshness checks.
2026-05-09 07:21:46 -07:00
matt wilkie
f52c78b2a1 fix(setup): finish hook JSON migration 2026-05-08 09:21:39 -07:00
Scott Hamilton
287d8a84c8 feat(setup): Gemini/Claude hook JSON compliance, --hook-json flag, legacy migration
Fixes Gemini CLI hook integration by emitting the required SessionStart JSON envelope. Extends the same standard to Claude Code hooks (documented spec, not just tolerated raw text). Adds legacy detection in bd setup gemini --check.

- Add `--hook-json` flag to `bd prime` wrapping output in the cross-CLI `hookSpecificOutput.additionalContext` JSON envelope (Claude Code, Gemini CLI, and Codex all share this contract)
- Update `bd setup gemini` to register `bd prime --hook-json` on SessionStart; remove PreCompress registration (advisory-only, no additionalContext support per Gemini docs v0.40.1)
- Update `bd setup claude` to register `bd prime --hook-json` on SessionStart and PreCompact (JSON form is the documented spec; raw text was merely tolerated)
- Migration sweeps in both setup commands so re-running upgrades bare-command installs cleanly
- `bd setup gemini --check` distinguishes current (`--hook-json`) from legacy (bare `bd prime`) installs and emits upgrade advisory for legacy
- Fix `removeHookCommand` bug: previously dropped entire hook entry on first command match, silently deleting sibling commands; now filters only the matching command and drops the entry only when empty
- Refresh docs and recipes to reflect SessionStart-only Gemini hook behavior

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-05-08 09:16:25 -07:00
matt wilkie
02bdb4ce4b
fix(prime): surface memories before hook truncation (#3692) 2026-05-05 20:26:07 -07:00
matt wilkie
2e1a0dd56f
docs(codex): add skill path hint and marker-coexistence note (#3735)
Address PR #3670 review nits:

1. The managed Codex AGENTS.md section pointed at "the beads skill"
   without saying where SKILL.md lives. Codex does not auto-discover
   .agents/skills/, so include explicit project and global paths in
   the section body so an agent reading AGENTS.md can find the skill.

2. bd setup codex uses its own BEADS CODEX SETUP markers, separate
   from the BEADS INTEGRATION markers used by factory/mux. Document
   in docs/SETUP.md that both can coexist in the same AGENTS.md and
   that each setup's --check/--remove only touches its own section.
2026-05-05 19:35:01 -07:00
Eugene Brevdo
4f1c296708
Add explicit Codex skill setup (#3670)
* Add explicit Codex skill setup

* Refine Codex setup guidance
2026-05-05 19:33:35 -07:00
Okano, Osamu
ef6c6e3e48
Follow up remaining runtime .beads fallbacks after GH#3124 (#3183)
* fix(workspace): align resolved workspace messaging and config lookup

intent(workspace): pure worktrees and external BEADS_DIR setups should work without implying a local .beads directory is required
decision(config): derive config repo roots from FindBeadsDir-backed workspace resolution instead of a local-only .beads walk
constraint(workspace-detection): keep FindBeadsDir ordering and storage behavior unchanged while making bd where the primary diagnostic hint
learned(testing): shared-server env and global .beads ignore rules can distort CGO suites, so regression coverage now normalizes those test paths

* fix(bootstrap): align no-workspace JSON wording

intent(bootstrap): machine-readable no-workspace output should match the resolved-workspace guidance used elsewhere on this branch
decision(bootstrap-json): reuse the shared workspace error helpers through a dedicated payload builder so tests can lock the JSON contract
constraint(review-loop): keep the bootstrap CLI flow unchanged outside the no-workspace JSON branch while adding a focused regression test

* fix(where): allow no-workspace diagnostics without db (beads-9f74-5l1)

intent(where): no-workspace guidance should point to a command that actually runs when workspace resolution fails
decision(startup): treat top-level where as a no-db command so it reaches its own handler before database preflight
constraint(where-tests): subprocess mode can change the exact hint text, so the regression test locks the JSON contract and stable guidance fragments instead

* fix(bootstrap): restore bd where guidance for no-workspace output (beads-9f74-3c3)

intent(bootstrap): no-workspace bootstrap guidance should match the resolved-workspace diagnostics introduced on this branch
decision(no-workspace-hints): reuse the shared hint that mentions bd where instead of the bootstrap-specific fallback text
constraint(bootstrap-tests): cover both the payload helper and subprocess CLI path so wording regressions are caught before release

* fix(workspace): remove no-workspace .beads fallbacks (beads-9f74-gr1)

intent(workspace-resolution): finish the GH#3124 follow-up for runtime paths that still fabricated local .beads state
rejected(no-workspace-fallback): inventing ./ .beads paths outside an active workspace hid shared-worktree resolution and created stray files
decision(setup-recipes): keep built-in bd setup recipes usable without a workspace but require an active workspace for custom recipe state
constraint(worktree-support): completion and backup helpers still need to resolve shared main-repo workspaces from a git worktree

* fix(config): skip no-workspace store init for store-free commands

intent(config): review-fix-loop found no-workspace config commands should reach their own graceful paths instead of failing in PersistentPreRun
decision(config-preflight): detect store-free config subcommands before DB synthesis so config.yaml, git-backed, and diagnostic flows can run without an opened store
constraint(json-contract): keep bd config validate --json machine-readable on stdout once pre-run stops short-circuiting into low-level DB errors
learned(config-preflight): the parent config command not being in noDbCommands leaked store init into show, validate, drift, apply, and yaml-only config helpers

* fix(ci): restore init prefix normalization and formatting

intent(ci): clear the current PR failures instead of leaving the branch blocked behind known red checks

decision(init-prefix): normalize dotted prefixes before persisting issue_prefix so config, metadata.json, and Dolt database naming stay aligned for Julia-style repos
constraint(fmt-check): CI runs gofmt over the whole repo, so the existing spacing drift in internal/jira/tracker_test.go had to be cleaned up on this branch to get a green run
learned(ci): the latest main CI was already red on the same formatting file and the same embedded shard, so rebasing surfaced pre-existing blockers rather than introducing a new shard-only regression
2026-04-10 21:23:14 -07:00
maphew
6edd905b1b feat(setup): target CLAUDE.md and GEMINI.md for hooks integrations
Amp-Thread-ID: https://ampcode.com/threads/T-019cf2bd-bf1b-7269-abd8-ec65edb98bd5
Co-authored-by: Amp <amp@ampcode.com>
2026-03-15 15:02:52 -07:00
maphew
a0720f2402 feat: prime SSOT tasks 8-12 — init upgrade, recipe cleanup, symlink safety, staleness detection (#2139)
Task 8: bd init now upgrades legacy beads sections to versioned format
instead of silently skipping them. New files created via EmbeddedDefault()
also get versioned markers.

Task 9: Replace stale bd sync references with bd dolt push in recipes
template. Add bd prime SSOT messaging.

Task 10: installAgents resolves symlinks via ResolveForWrite before
reading content. Profile precedence: if file already has full profile
and minimal is requested, full is preserved to avoid information loss.

Task 11: Added tests for staleness detection, profile extraction,
profile precedence, symlink safety, and legacy-to-new migration.
checkAgents now reports stale/current/missing status.

Task 12: Updated SETUP.md with prime SSOT, profiles, and profile
precedence documentation. Updated CLI_REFERENCE.md with --check
behavior and Gemini integration description.

Amp-Thread-ID: https://ampcode.com/threads/T-019ced7a-0c86-708d-930c-ee35d00eda8d
Co-authored-by: Amp <amp@ampcode.com>
2026-03-15 15:02:52 -07:00
matt wilkie
e05cd7ed13
docs: replace stale bd sync references with bd dolt push/pull (GH#2442, GH#2435)
Amp-Thread-ID: https://ampcode.com/threads/T-019cce5b-39df-740f-a8e1-5c6b3e389519

Co-authored-by: Amp <amp@ampcode.com>
2026-03-08 10:12:08 -07:00
darcy
f9b306f152 docs(claim): standardize start-work semantics to --claim (#2070)
Standardize start-work semantics to `bd update <id> --claim` across docs,
examples, templates, and website static LLM artifacts. Replaces
`--status in_progress` with `--claim` where the meaning is start-work.

Also fixes stale comment in llms.txt ("Update status" → "Start work").

Co-Authored-By: Valeriy Pavlovich <iqdoctor@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 22:11:39 -08:00
beads/crew/lizzy
f383ce3efd feat(setup): add Mux setup recipe with layered AGENTS and managed hooks
Adds bd setup mux with support for layered AGENTS.md installation
(root, project .mux/, global ~/.mux/) and managed hook files
(.mux/init, .mux/tool_post, .mux/tool_env). Makes AGENTS removal
non-destructive (preserves user content outside managed markers).

From: PR #1888 by alexx-ftw (cherry-picked, rebased onto current main)

Co-Authored-By: Alexx <alexx-ftw@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 15:33:06 -08:00
matt wilkie
ce622f5688
feat(setup): add Codex CLI setup recipe (#1243)
* Add Codex setup recipe

* Sync beads issues (bd-1zo)

---------

Co-authored-by: Amp <amp@example.com>
2026-01-21 21:50:01 -08:00
dave
6730fce9b1 feat(setup): refactor to recipe-based architecture (bd-i3ed)
Replace tool-specific setup commands with a generic recipe-based system.
New tools become config entries, not code changes.

Changes:
- Add internal/recipes/ package with Recipe type and built-in recipes
- Add --list flag to show available recipes
- Add --print flag to output template to stdout
- Add -o flag to write template to arbitrary path
- Add --add flag to save custom recipes to .beads/recipes.toml
- Add built-in recipes: windsurf, cody, kilocode (new)
- Legacy recipes (cursor, claude, gemini, aider, factory) continue to work

The recipe system enables:
- Adding new tool support without code changes
- User-defined recipes in .beads/recipes.toml
- Shared template across all file-based integrations

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

Executed-By: beads/crew/dave
Rig: beads
Role: crew
2026-01-04 21:57:09 -08:00
beads/crew/wolf
a06b40bd48 feat: add bd setup gemini for Gemini CLI integration (#845)
Add support for Gemini CLI hook-based integration, similar to Claude Code:
- bd setup gemini: Install SessionStart/PreCompress hooks
- bd setup gemini --check: Verify installation
- bd setup gemini --remove: Remove hooks
- bd setup gemini --project: Project-only installation
- bd setup gemini --stealth: Use bd prime --stealth

Also adds Gemini CLI integration check to bd doctor.

Gemini CLI's hook system is nearly identical to Claude Code's,
making this a clean, low-maintenance addition.

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

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 00:02:38 -08:00
Jordan Hubbard
e0528de590
feat: add Factory.ai (Droid) support to bd setup command (#598)
Adds Factory.ai (Droid) support to bd setup command via AGENTS.md integration.

- New command: bd setup factory (with --check and --remove flags)
- Creates/updates AGENTS.md with beads workflow instructions
- Uses HTML comment markers for safe idempotent updates
- Comprehensive documentation

Thanks @jordanhubbard!
2025-12-16 13:42:43 -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