|
2 | 2 |
|
3 | 3 | ## Development |
4 | 4 |
|
5 | | -- `locksmith mcp run --url` now triggers templated-header resolution |
6 | | - not only on HTTP `401/403` but also when the remote MCP server |
7 | | - returns `200 OK` with a JSON-RPC `error` field or a tool-level |
8 | | - `result.isError: true`. Resolution and retry happen exactly once |
9 | | - per session; if the retry also fails, the error is forwarded to the |
10 | | - AI client unchanged. Detection looks only at structural fields - no |
11 | | - keyword matching against `result.content[].text`. |
12 | | -- Per-agent installer logic moved into `internal/initflow/agents/<name>/` |
13 | | - subpackages (claude, codex, gemini, opencode, generic), each with |
14 | | - embedded templates. `AgentWriter` in `agents.go` is now a thin switch |
15 | | - dispatcher. Gemini CLI is now detected by `DetectAgents` and dispatched |
16 | | - to the new `gemini` subpackage (previously dead code). The dead |
17 | | - `agents_md.md.tmpl` template was removed. |
18 | | -- `locksmith init` now adds `Bash(locksmith:*)` to |
19 | | - `permissions.allow` in `~/.claude/settings.json` so the agent can |
20 | | - call `locksmith` directly without per-call approval. Idempotent. |
21 | | -- Agent instruction templates (Claude/Codex/Gemini/OpenCode and the |
22 | | - generic agent file) are now wrapped with `<!-- LOCKSMITH_START -->` |
23 | | - / `<!-- LOCKSMITH_END -->` markers so the locksmith-managed block |
24 | | - can be located and updated reliably. |
25 | | -- `locksmith restart` command added: stops the running daemon and |
26 | | - starts a fresh one. Flags `--timeout` and `--no-start`. Use after a |
27 | | - binary upgrade or plugin re-extract; see `docs/restart.md`. |
28 | | -- `locksmith init` appends an idempotent PATH-augmentation block to |
29 | | - the user's shell rc (`~/.zshrc` / `~/.bashrc` / |
30 | | - `~/.config/fish/config.fish`) when the locksmith binary directory |
31 | | - is not already on `$PATH`. Skipped silently when the directory is |
32 | | - already on PATH or when the rc file does not exist (init never |
33 | | - creates new rc files). |
34 | | -- Add `vaults.<name>.vault` config field, delivered to plugins as `opts["vault"]`; used by the 1Password plugin to qualify non-`op://` paths. |
35 | | -- Add 1Password vault plugin backed by the op CLI, auto-detected when `op` is installed. |
36 | | -- docs(cli): drop Touch ID wording from CLI help, README, configuration |
37 | | - and architecture docs, and plugin READMEs; keychain authorization is |
38 | | - described as OS-delegated without naming a specific auth method |
39 | | -- docs: split development-time tooling out of `LICENSE` into the new |
40 | | - `docs/development-tools.md`; build tools (buf, golangci-lint) and |
41 | | - external AI agent tooling (CodeGraph MCP server, obra/superpowers |
42 | | - skill pack) are listed there instead. The `check-licenses` skill |
43 | | - and `CONTRIBUTING.md` were updated to match. |
44 | | -- Switch the Claude Code UserPromptSubmit hook from a shell script to |
45 | | - the native `locksmith session ensure --hook` invocation. The flag |
46 | | - produces a JSON env block via `encoding/json` (no `printf`, no |
47 | | - `$(...)`). |
48 | | -- Auto-migrate existing installs: legacy `agent-hook.sh` references in |
49 | | - `~/.claude/settings.json` are rewritten in place on the next |
50 | | - `locksmith init`, the matching `Bash(.../agent-hook.sh)` permission |
51 | | - rule is dropped, and the on-disk script is removed. |
52 | | -- `locksmith init` now automatically restarts a running daemon at the |
53 | | - end of its run so plugin/config changes take effect immediately. |
54 | | -- `locksmith init` now installs a Codex `SessionStart` hook in |
55 | | - `~/.codex/hooks.json` when Codex is detected. The hook pre-warms |
56 | | - the locksmith daemon so vault unlock (passphrase, biometric) fires |
57 | | - before the agent's first secret request. Best-effort: any failure |
58 | | - is swallowed so Codex startup is never blocked. Codex prompts the |
59 | | - user to trust the hook on next run. |
60 | | -- Agent instruction templates are now agent-specific: each template |
61 | | - describes only its own agent's session protocol (Claude relies on |
62 | | - the UserPromptSubmit hook; Codex / Gemini CLI / OpenCode / generic |
63 | | - use `export LOCKSMITH_SESSION=$(locksmith session ensure --quiet)`) |
64 | | - and includes usage examples for all three shipped vault types |
65 | | - (`gopass`, `keychain`, `1password`). |
66 | | -- Agent templates now document an MCP-wrapper fallback: when a locksmith-wrapped MCP server fails, the agent parses `--header` and `--env` templates from its own MCP config, resolves them via `locksmith get`, and runs the server directly. Templates also whitelist `session ensure`, `serve`, and `get` as the only runtime locksmith commands. |
67 | | -- The verification GPG gate now ignores GitHub-generated "Merge pull request" commits: their `web-flow` signature is often expired locally and they cannot be re-signed without diverging from the remote. |
68 | | -- Agent templates now document a recovery prompt for external HTTP API auth failures: on the first 401/403 for a hostname, the agent asks the user to (1) Skip, (2) provide a locksmith key or vault+path, or (3) paste the token directly. Resolved tokens are cached per hostname for the rest of the session; Skip suppresses further prompts for that hostname. |
69 | | -- Tightened the runtime-whitelist, MCP-fallback, and external-API auth-failure sections in agent templates (~45% shorter; same semantics). The MCP fallback now opens with an explicit "execute these steps; do not ask the user clarifying questions" directive so smaller models commit to the recovery path instead of pausing for confirmation. Validated across multiple parallel sub-agent runs on Sonnet and Haiku covering both flows. |
| 5 | +## Version v0.4.0 - 2026-05-24 |
| 6 | + |
| 7 | +### Features |
| 8 | + |
| 9 | +- `locksmith mcp run --url` now resolves templated headers on JSON-RPC `error` or tool-level `result.isError`, not only on HTTP `401/403`; one retry per session, structural-only detection (no keyword matching on `result.content[].text`) |
| 10 | +- add 1Password vault plugin (backed by the `op` CLI; auto-detected when `op` is installed) |
| 11 | +- add `vaults.<name>.vault` config field, delivered to plugins as `opts["vault"]`; used by the 1Password plugin to qualify non-`op://` paths |
| 12 | +- add `locksmith restart` command with `--timeout` / `--no-start` (see `docs/restart.md`) |
| 13 | +- per-agent installer logic moved into `internal/initflow/agents/<name>/` subpackages; Gemini CLI is now actually detected and dispatched (previously dead code) |
| 14 | +- agent instruction templates are wrapped with `<!-- LOCKSMITH_START -->` / `<!-- LOCKSMITH_END -->` markers so the managed block can be located and updated reliably |
| 15 | +- agent instruction templates are now agent-specific: per-agent session protocol (Claude via `UserPromptSubmit` hook; Codex / Gemini / OpenCode / generic via `export LOCKSMITH_SESSION=$(locksmith session ensure --quiet)`) and usage examples for `gopass`, `keychain`, `1password` |
| 16 | +- agent templates document an MCP-wrapper fallback: when a wrapped MCP server fails, the agent resolves `--header` / `--env` templates via `locksmith get` and runs the server directly |
| 17 | +- agent templates document an external HTTP API auth-failure recovery prompt: on the first `401/403` for a hostname, the agent offers Skip / locksmith key or vault+path / paste-token; resolved tokens are cached per hostname for the session |
| 18 | +- `locksmith init` adds `Bash(locksmith:*)` to `permissions.allow` in `~/.claude/settings.json` so the agent can call `locksmith` directly (idempotent) |
| 19 | +- `locksmith init` appends an idempotent PATH-augmentation block to `~/.zshrc` / `~/.bashrc` / `~/.config/fish/config.fish` when the locksmith binary directory is not already on `$PATH` (never creates new rc files) |
| 20 | +- `locksmith init` now auto-restarts the running daemon at the end of its run so plugin/config changes take effect immediately |
| 21 | +- `locksmith init` installs a Codex `SessionStart` hook in `~/.codex/hooks.json` when Codex is detected; the hook pre-warms the daemon so vault unlock fires before the agent's first secret request (best-effort; failures swallowed) |
| 22 | +- Claude Code `UserPromptSubmit` hook switched to the native `locksmith session ensure --hook` invocation (JSON env block via `encoding/json`, no shell script); existing installs are auto-migrated on next `locksmith init` (legacy `agent-hook.sh` references rewritten in place, matching `Bash(.../agent-hook.sh)` permission rule dropped, on-disk script removed) |
70 | 23 |
|
71 | 24 | ## Version v0.3.0 - 2026-05-15 |
72 | 25 |
|
|
0 commit comments