You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(index): cross-process lock, unlock CLI, and errors.log (#129)
Acquire <state-dir>/index.lock before indexing with in-process serialization,
fail-fast when another live indexer holds the lock, and append parse failures
to errors.log. Adds codemap unlock for stale lock recovery.
Copy file name to clipboardExpand all lines: docs/agents.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,8 @@ All integrations reuse the **same** bundled content under **`.agents/`**. Symlin
60
60
61
61
When the file watcher is off (WSL `/mnt/*` mounts, `CODEMAP_WATCH=0`, etc.), **`codemap agents init --git-hooks`** installs marker-delimited blocks in **`post-commit`**, **`post-merge`**, and **`post-checkout`** that run `( codemap >/dev/null 2>&1 & )` — non-blocking background incremental index. **`--no-git-hooks`** removes only codemap-marked blocks. Interactive init offers hooks automatically when [`watch-policy.ts`](../src/application/watch-policy.ts) would disable the watcher for the project root.
62
62
63
+
Concurrent indexers (CLI, MCP `--watch`, git hooks) coordinate via **`<state-dir>/index.lock`**. If indexing fails with “Index already running” after a crash, run **`codemap unlock`**. Per-file parse failures append to **`<state-dir>/errors.log`**.
64
+
63
65
## Pointer files
64
66
65
67
Root / Copilot **pointer** files (**`CLAUDE.md`**, **`AGENTS.md`**, **`GEMINI.md`**, **`.github/copilot-instructions.md`**) use a **managed section** between **`<!-- codemap-pointer:begin -->`** and **`<!-- codemap-pointer:end -->`** (HTML comments — usually hidden in rendered Markdown):
|**1**|[`mcp-server-instructions`](./mcp-server-instructions.md) + [`mcp-tool-allowlist`](./mcp-tool-allowlist.md)|open |[`feat/mcp-instructions-allowlist`](https://github.com/stainless-code/codemap/pull/126)| Same hot files (`mcp-server.ts`, `agent-content`); ~3–4 days |
32
-
|**2**|[`wsl-watch-policy`](./wsl-watch-policy.md) → [`git-hook-auto-sync`](./git-hook-auto-sync.md)|open |[`feat/wsl-watch-git-hooks`](https://github.com/stainless-code/codemap/pull/127)|`watch-policy.ts` first; hooks reference it in diagnostics. Lock deferred to PR 3 — note concurrent hook + MCP in PR 2 body |
29
+
| PR | Plans bundled | Status | Branch / link | Notes |
|**1**|[`mcp-server-instructions`](./mcp-server-instructions.md) + [`mcp-tool-allowlist`](./mcp-tool-allowlist.md)|merged |[#126](https://github.com/stainless-code/codemap/pull/126)| Same hot files (`mcp-server.ts`, `agent-content`); ~3–4 days |
32
+
|**2**|[`wsl-watch-policy`](./wsl-watch-policy.md) → [`git-hook-auto-sync`](./git-hook-auto-sync.md)|merged |[#127](https://github.com/stainless-code/codemap/pull/127)|`watch-policy.ts` first; hooks reference it in diagnostics. Lock deferred to PR 3 — note concurrent hook + MCP in PR 2 body |
33
33
34
34
### Wave 2 — P1 (~2–3 weeks, parallel tracks)
35
35
36
36
Max **3 parallel tracks** at once.
37
37
38
-
| PR | Plans | Status | Blocked by | Parallel with |
0 commit comments