Commit graph

7 commits

Author SHA1 Message Date
matt wilkie
dfa8ea4813
fix(docgen): generate CLI docs in one process (#4474)
Add a bulk help docs writer that emits the root CLI reference and website command pages from a single Cobra walk. Update the shell generator to call that mode, preserve the pure-Go docs binary guard, and refresh historical versioned CLI docs only when release snapshotting requests a specific version.

Agent-Signature: codex-gpt-5.5-medium on behalf of matt wilkie
2026-06-22 18:25:58 -07:00
Steve Yegge
4e460b427b
fix(is_blocked): cross-mode full recompute repair for stale is_blocked (bd-6dnrw.37) (#4423)
* fix(is_blocked): cross-mode full recompute repair for stale is_blocked (bd-6dnrw.37)

The post-pull is_blocked recompute (bd-6dnrw.3) is scoped to the merge diff and
skips when a re-pull merges nothing (HEAD unchanged), so a recompute that failed
AFTER its merge committed — or a conflicted pull resolved by hand (which skips
the recompute) — left is_blocked stale with no repair: rerunning bd dolt pull
merged nothing and recomputed nothing. bd ready trusts is_blocked, so stale
values silently hide ready work or surface blocked work.

Core (internal/storage/issueops/blocked_consistency.go):
- RecomputeAllIsBlockedInTx: full mark/unmark fixpoint over every issue+wisp,
  returns rows corrected. Idempotent. Reuses the existing pass functions.
- CountIsBlockedInconsistenciesInTx: read-only COUNT of stale rows for detection.
  Its predicate mirrors the mark/unmark templates and is pinned to the repair by
  the dolt-package lockstep tests (a converged DB counts 0; any counted row is
  one a recompute pass flips), so detection cannot silently drift from repair.

Cross-mode repair:
- storage.BlockedRecomputer capability; DoltStore + EmbeddedDoltStore
  RecomputeAllBlocked (stage issues-only, matching the post-pull recompute).
- New 'bd recompute-blocked' command — works in BOTH embedded and server mode.
  bd doctor is server-mode only, so embedded users need a non-doctor entry point.
- bd doctor (server mode) gains a read-only "Blocked State" check and a
  'bd doctor --fix' dispatch running the same repair. Warn-only (does not fail
  OverallOK): new check shipping in a patch, is_blocked self-heals via the fix.

Secondary item (server recomputeBlockedAfterPull commits via s.Commit, which can
sweep a concurrent writer's changes) split to bd-6y5hx (P3, deferred): it is
subtle (after an auto-resolved merge the working set holds the whole merge
result, so a naive issues-only narrowing would drop merge results). The embedded
path already stages issues-only; the new repair path stages issues-only too.

Tests: 3 dolt lockstep tests (detect==repair, stuck-blocked, parent-child
cascade) + embedded wiring test. Smoke-tested on a real ~2000-issue embedded DB:
0 false positives. build/vet/gofmt/golangci-lint all clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* docs: regenerate CLI reference for `bd recompute-blocked`

Run ./scripts/generate-cli-docs.sh + ./scripts/generate-llms-full.sh with
the canonical CGO_ENABLED=0 gms_pure_go build to pick up the new
`bd recompute-blocked` command. The adopted PR added the command but did
not regenerate the CLI docs, failing the PR doc-flags freshness checks.

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

* fix(is_blocked): guard full recompute against dirty graph; pin doctor blocked-state last

Maintainer adoption fixes for PR #4423 review (bd-6dnrw.37):

- Refuse a full is_blocked recompute when the committable graph tables
  (issues, dependencies) carry uncommitted working-set changes, across the
  server, embedded, and doctor-fix paths. The recompute derives flags from
  the current graph and stages only `issues`, so running it dirty would
  sweep unrelated issue edits into the repair commit or publish is_blocked
  derived from uncommitted dependency state. Dolt-ignored wisp tables are
  deliberately excluded from the guard: they are never committed and show
  as perpetually modified in dolt_status, so guarding on them would refuse
  the recompute in any workspace that uses wisps.

- Pin the doctor "Blocked State" fix to an explicit terminal priority so it
  provably runs after every graph-mutating fix (Dependency Keys,
  Orphaned/Child-Parent Dependencies, Cross-Table Duplicates) instead of
  relying on check-append order. This fixes a stale is_blocked left after
  `bd doctor --fix --fix-child-parent` removed a child-parent edge.

- Surface (no longer swallow) the doctor-fix Dolt stage/commit errors, and
  tolerate only the benign nothing-to-commit case.

Tests: dirty-issues and dirty-dependencies refusal, dirty-wisps still
repairs, clean repair+commit idempotence (dolt server-mode); fix-ordering
regression covering the --fix-child-parent case (cmd/bd); embedded wiring
test now commits its seed to match the fresh-process clean-tree precondition.

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

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Eddie the Engineer <ci@beads.test>
2026-06-19 23:14:09 -07:00
matt wilkie
b2a4d1d04a
docs: generate CLI reference from live help (#3704)
* docs: generate CLI reference from live help

* docs(cli): move bd version stamp from per-command pages to index only

Drops the `(bd version X.Y.Z)` suffix from the auto-generated header on
every per-command CLI reference page (writeSingleCommandDoc) and the
docs/CLI_REFERENCE.md preamble (writeAllHelp). The version label now
lives only on the index page emitted by scripts/generate-cli-docs.sh:

- Dev tree (website/docs/cli-reference/index.md, docs/CLI_REFERENCE.md):
  labelled "Latest"
- Versioned snapshots (website/versioned_docs/version-X.Y.Z/...):
  labelled with the explicit semver tag parsed from the directory name

This eliminates the 100+-file no-signal diff a release version bump
otherwise produces, restoring the "regen as a separate small commit"
workflow PR #3704 enables. After this change a version bump alone
yields zero diff on the dev tree; only the new versioned snapshot
created at release-cut time carries the new tag. No datestamps are
introduced anywhere — scripts/generate-cli-docs.sh --check remains
deterministic across CI runs.

Refs: mybd-afb, PR #3704

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: CI Bot <ci@beads.test>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 19:43:49 -07:00
Amp
a333dcaa75 fix(docs): purge stale bd sync/import/--branch refs + add CI doc validation (GH#2522)
Systematic cleanup of stale documentation references left over from the
Dolt migration:

- Replace all 'bd sync' → 'bd dolt push' / 'bd dolt pull' across 40+ files
- Replace all 'bd import' → 'bd init --from-jsonl' or remove
- Replace 'bd init --branch' → note about refs/dolt/data separation
- Fix AGENT_INSTRUCTIONS.md (highest impact: agents read this directly)
- Fix npm-package, claude-plugin, integrations, examples, website docs

Add scripts/check-doc-flags.sh to catch stale doc references:
- Checks for removed commands (bd sync, bd import)
- Checks for removed flags (bd init --branch)
- Warns on legacy SQLite/beads.db references
- Compares CLI_REFERENCE.md against bd help --all

Add CI job (check-doc-flags) and Makefile target (check-docs) to gate
PRs against doc freshness.

Prior art: feat/help-doc-generator branch has bd help --doc/--list for
generating docs FROM CLI output. This script validates docs AGAINST CLI
output — complementary approaches.

Amp-Thread-ID: https://ampcode.com/threads/T-019cde77-0722-7353-b63a-1779a5773ca6
Co-authored-by: Amp <amp@ampcode.com>
2026-03-11 13:25:40 -07:00
beads/crew/elinor
90da8f6028 docs: remove stale JSONL references from ~73 markdown files (bd-9ni.4)
Replace JSONL storage/sync references with Dolt-native equivalents across
documentation, plugin resources, website docs, agent instructions, and
example READMEs. Preserves legitimate JSONL references (bd import/export
commands, CHANGELOG history, routes.jsonl/interactions.jsonl concepts).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 22:18:02 -08:00
topaz
062aedbed7 docs: remove stale daemon references from all documentation (GH#1982)
Sweep 65 markdown files across docs/, website/, claude-plugin/, examples/,
integrations/, and root to replace removed `bd daemon` references with
current Dolt server mode equivalents. CHANGELOG.md preserved per policy.

Key replacements:
- `bd daemon start/stop/status` → `bd dolt start/stop` / `bd doctor`
- `bd daemons killall/health/logs` → `bd dolt stop` / `bd doctor`
- `--no-daemon` flag → removed (embedded mode is default)
- `BEADS_NO_DAEMON` / `BEADS_DAEMON_MODE` env vars → removed
- `.beads/bd.sock` → removed
- "daemon mode" / "direct mode" → "server mode" / "embedded mode"
- daemon.pid/daemon.log → .beads/dolt/sql-server.pid/.log

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

Executed-By: beads/polecats/topaz
Rig: beads
Role: polecats
2026-02-22 17:57:53 -08:00
Steve Yegge
584608a14e feat: add llms.txt standard support for AI agent discoverability (#784)
Cherry-picked website/, scripts/generate-llms-full.sh, and deploy-docs.yml
from joyshmitz's PR. Fixed workflow to trigger on main branch instead of
docs/docusaurus-site.

Features:
- Docusaurus documentation site with llms.txt support
- Environment-variable driven config (defaults to steveyegge org)
- Automated llms-full.txt generation from docs
- GitHub Pages deployment workflow

Co-authored-by: joyshmitz <joyshmitz@users.noreply.github.com>

🤖 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
2025-12-30 18:27:50 -08:00