Reverts PR #3498 / commit 0fffa44a2302a496dfa4ffa838843b3bbf0ee122.\n\nPR #3498 added BEADS_DOLT_CLI_DIR routing without a confirmed reproduction and introduced an external-server push/pull regression. Remove that override and its docs/tests so main no longer requires a local CLI database directory in external-server mode.\n\n_codex-gpt-5- on behalf of CI Bot_
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)
* fix(dolt): skip git hooks on internal push of refs/dolt/data (GH#3724)
bd dolt push fails with 'fatal: this operation must be run in a work tree' when the user's init.templateDir has populated the embedded Dolt cache-mirror's hooks/ dir with a pre-push hook (e.g. via pre-commit-framework). Dolt's internal 'git push refs/dolt/data' against the bare-style cache repo fires that hook, which then calls 'git diff' and bombs out.
Set GIT_CONFIG_PARAMETERS='core.hooksPath=/dev/null' on the subprocess env in doltCLIPush so any git invocation made by dolt skips client-side hooks. Same family / shape as the commit-side fixes in PR #3626 (GH#3340) and PR #3599 (GH#3598) — different commit site.
Tests: unit tests on the new applyNoGitHooksToCmd helper (run on regular CI), plus an integration regression test that drops a failing pre-push hook into the cache-mirror after a first push and verifies the second push succeeds without firing it (//go:build integration; runs nightly).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* address self-review nits proactively
- Apply the same fix to doltCLIPushRefToPeer (federation peer push) — same file, same root cause, same one-liner. Federation pushes against git-protocol peers go through Dolt's git-remote-cache mirror with the same pre-push hook exposure.
- Trim the verbose call-site comment in doltCLIPush down to a single GH#3724 reference, matching the existing style of applyS3ChecksumEnvToCmd. Full context lives in the helper docstring.
- Skip TestGitRemotePushSkipsUserPrePushHook on Windows: the assertion uses a POSIX shell hook script. The bug and fix are platform-agnostic; only the test artefact isn't.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>