opengrok-mcp-server 3.3.5 β 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +126 -3
- package/CONTRIBUTING.md +41 -30
- package/MCP_CLIENTS.md +6 -6
- package/README.md +195 -127
- package/evaluation.xml +88 -0
- package/out/extension.js +1 -1
- package/out/server/main.js +285 -128
- package/out/server/sandbox-worker.js +2 -0
- package/package.json +47 -5
- package/scripts/release.ps1 +2 -1
- package/server.json +21 -20
- package/skills/opengrok/SKILL.md +266 -0
- package/vitest.sandbox.config.ts +18 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## Highlights
|
|
9
9
|
|
|
10
|
+
### 𧬠v5.0 β Code Mode: Pure-WASM Sandbox + Token Optimization
|
|
11
|
+
|
|
12
|
+
Code Mode sandbox built on `@sebastianwessel/quickjs` β pure JS + WASM, zero native compilation, no `node-gyp`, works everywhere including `npx` and enterprise Linux. Full token optimization suite: three context budget tiers, compact TSV/YAML/text formats, Living Document memory bank, and session observation masker for long investigations.
|
|
13
|
+
|
|
14
|
+
### ποΈ v4.0 β Modern MCP SDK & Breaking Tool Rename
|
|
15
|
+
|
|
16
|
+
McpServer high-level API, `opengrok_` prefixed tool names, tool annotations, structured output, `response_format` parameter, security hardening. Full protocol compliance.
|
|
17
|
+
|
|
10
18
|
### π§ v3.0 β Code Intelligence Engine
|
|
11
19
|
|
|
12
20
|
6 new compound tools, ~92% fewer tokens, full OpenGrok 1.7.x support, and a zero-config local source layer that knows your compiler flags. The largest update since the original rewrite.
|
|
@@ -23,14 +31,129 @@ Native MCP integration, OS keychain credentials, 8 OpenGrok tools, SSRF protecti
|
|
|
23
31
|
|
|
24
32
|
---
|
|
25
33
|
|
|
34
|
+
## [5.0.0] - 2026-03-20
|
|
35
|
+
|
|
36
|
+
Reduces LLM token consumption 80β95% on large C++ codebases. Zero new background processes. Zero impact on shared build machines. Works standalone (Claude Code CLI, `npx`) with no native compilation or Node flags required.
|
|
37
|
+
|
|
38
|
+
### Changed (Behavioural Defaults)
|
|
39
|
+
|
|
40
|
+
- **`opengrok_search_and_read` `context_lines` default**: 10 β 5 lines. Pass `context_lines: 10` explicitly to restore previous behaviour.
|
|
41
|
+
|
|
42
|
+
### Added
|
|
43
|
+
|
|
44
|
+
#### Phase 1 β Cache-Safe Server Cleanup
|
|
45
|
+
- Rewrote `SERVER_INSTRUCTIONS`: numbered rules, no runtime interpolation, token-efficient.
|
|
46
|
+
- Full-file fetch guard in `opengrok_get_file_content`: warns + auto-applies line range when file exceeds 50 lines and no range given.
|
|
47
|
+
|
|
48
|
+
#### Phase 2 β Compact Response Formats
|
|
49
|
+
- **TSV format** for search results: `formatSearchResultsTSV()` β ~58% fewer tokens than markdown, tab-delimited (safe for C++ signatures with colons).
|
|
50
|
+
- **YAML format** for symbol context: `formatSymbolContextYAML()` β js-yaml block scalars handle C++ colons/hashes safely.
|
|
51
|
+
- **Text format** for file content: `formatFileContentText()` β no fenced code block overhead.
|
|
52
|
+
- **`selectFormat()`**: auto-selects best format by response type; override globally with `OPENGROK_RESPONSE_FORMAT_OVERRIDE`.
|
|
53
|
+
|
|
54
|
+
#### Phase 3 β Context Budget Modes
|
|
55
|
+
- **`OPENGROK_CONTEXT_BUDGET`** env var with three tiers:
|
|
56
|
+
- `minimal` (default) β 4 KB responses, 5 results, 50 inline lines
|
|
57
|
+
- `standard` β 8 KB, 10 results, 100 lines
|
|
58
|
+
- `generous` β 16 KB, 25 results, 200 lines
|
|
59
|
+
- `capResponse()` now reads from `BUDGET_LIMITS`; `search_and_read` cap also budget-aware.
|
|
60
|
+
|
|
61
|
+
#### Phase 4 β Code Mode (2-Tool Interface)
|
|
62
|
+
- **`OPENGROK_CODE_MODE=true`**: activates 2-tool mode (`opengrok_api` + `opengrok_execute`) for large C++ codebases. Write JavaScript; all `env.opengrok.*` calls appear synchronous. Token savings vs. 14-tool standard mode are substantial for multi-step investigations.
|
|
63
|
+
- **`opengrok_api`**: returns full API spec (call once at session start).
|
|
64
|
+
- **`opengrok_execute`**: runs LLM-written JS in a sandboxed QuickJS VM.
|
|
65
|
+
- **`opengrok_read_memory` / `opengrok_update_memory`**: direct memory bank access from standard MCP clients.
|
|
66
|
+
- **Server-side intelligence**:
|
|
67
|
+
- `env.opengrok.getFileOverview()` β parallel symbols + history + imports fetch; replaces 3β5 sequential tool calls.
|
|
68
|
+
- `env.opengrok.traceCallChain()` β refs-based caller tracing up to depth 4 (callees require AST, intentionally unimplemented).
|
|
69
|
+
|
|
70
|
+
#### Phase 5 β Living Document / Memory Bank
|
|
71
|
+
- **Memory Bank**: 6 persistent markdown files (`AGENTS.md`, `codebase-map.md`, `symbol-index.md`, `known-patterns.md`, `investigation-log.md`, `active-context.md`). Stub sentinel detection, append mode, `investigation-log.md` trims at 32 KB on heading boundaries.
|
|
72
|
+
- **Observation Masker**: keeps last 10 full tool outputs in context; older turns compacted to key facts (file paths, line numbers, CamelCase symbols) to prevent context overflow during long sessions.
|
|
73
|
+
- **VS Code config**: three new settings (`codeMode`, `memoryBankDir`, `contextBudget`) wired to env vars via extension passthrough.
|
|
74
|
+
|
|
75
|
+
#### Phase 6 β QuickJS Sandbox Implementation
|
|
76
|
+
- **Sandbox**: `@sebastianwessel/quickjs` (pure JS + WASM) β no `node-gyp`, no native compilation, no `--node-snapshot` flags. Works on all platforms including `npx` and enterprise Linux with stripped symbols.
|
|
77
|
+
- **Architecture**: dedicated Worker thread + SharedArrayBuffer bridge. Worker calls `Atomics.wait()` (blocks worker thread); main thread event loop stays free for async OpenGrok HTTP calls, writes result, calls `Atomics.notify()`. Buffer layout: bytes 0β15 status (`Int32`), 16β19 length (`Uint32`), 20+ JSON payload (`Uint8`, 1 MB max).
|
|
78
|
+
- **Sandbox limits**: 9 s QuickJS interrupt timeout + 10 s hard `worker.terminate()`. Memory 128 MB, stack 4 MB.
|
|
79
|
+
- **`npm run test:sandbox`**: post-build sandbox integration tests (10 tests, requires `npm run compile` first, uses separate `vitest.sandbox.config.ts`).
|
|
80
|
+
|
|
81
|
+
### Testing
|
|
82
|
+
|
|
83
|
+
- **591 tests across 25 test files** (up from ~493 in v4.0), 92% line coverage, 93% branch coverage.
|
|
84
|
+
- New: `config-budget.test.ts`, `formatters-formats.test.ts`, `memory-bank.test.ts`, `observation-masker.test.ts`, `intelligence.test.ts`, `code-mode.test.ts`, `sandbox.test.ts`.
|
|
85
|
+
|
|
86
|
+
---
|
|
87
|
+
|
|
88
|
+
## [4.0.0] - 2026-03-15
|
|
89
|
+
|
|
90
|
+
### β οΈ Breaking Changes
|
|
91
|
+
|
|
92
|
+
- **Tool rename**: All 14 tools now use `opengrok_` prefix for namespace clarity per MCP best practices. Update any client configurations or scripts that reference tool names.
|
|
93
|
+
|
|
94
|
+
#### Migration Guide
|
|
95
|
+
|
|
96
|
+
| Old Name (v3.x) | New Name (v4.0) |
|
|
97
|
+
| ---------------- | --------------- |
|
|
98
|
+
| `search_code` | `opengrok_search_code` |
|
|
99
|
+
| `find_file` | `opengrok_find_file` |
|
|
100
|
+
| `get_file_content` | `opengrok_get_file_content` |
|
|
101
|
+
| `get_file_history` | `opengrok_get_file_history` |
|
|
102
|
+
| `browse_directory` | `opengrok_browse_directory` |
|
|
103
|
+
| `list_projects` | `opengrok_list_projects` |
|
|
104
|
+
| `get_file_annotate` | `opengrok_get_file_annotate` |
|
|
105
|
+
| `search_suggest` | `opengrok_search_suggest` |
|
|
106
|
+
| `batch_search` | `opengrok_batch_search` |
|
|
107
|
+
| `search_and_read` | `opengrok_search_and_read` |
|
|
108
|
+
| `get_symbol_context` | `opengrok_get_symbol_context` |
|
|
109
|
+
| `index_health` | `opengrok_index_health` |
|
|
110
|
+
| `get_compile_info` | `opengrok_get_compile_info` |
|
|
111
|
+
| `get_file_symbols` | `opengrok_get_file_symbols` |
|
|
112
|
+
|
|
113
|
+
- **Removed `zod-to-json-schema` dependency**: `McpServer.registerTool()` handles ZodβJSON Schema natively. No action needed unless you imported from `tool-schemas.ts`.
|
|
114
|
+
- **Deleted `tool-schemas.ts`**: Tool definitions are now registered inline via `registerTool()` in `server.ts`.
|
|
115
|
+
|
|
116
|
+
### Added
|
|
117
|
+
|
|
118
|
+
- **McpServer high-level API** (Phase 2): Migrated from deprecated `Server` + `setRequestHandler()` to `McpServer` + `registerTool()`. Each tool is self-contained with its own error handling.
|
|
119
|
+
- **Tool annotations** on all 14 tools: `readOnlyHint`, `destructiveHint`, `idempotentHint`, `openWorldHint` per MCP spec. `opengrok_get_compile_info` uses `openWorldHint: false` (local filesystem only).
|
|
120
|
+
- **`title` field** on all tool registrations for human-readable display.
|
|
121
|
+
- **`isError: true`** on all error responses per MCP spec. All three error types (ZodError, Error, unknown) handled via shared `makeToolError()` helper.
|
|
122
|
+
- **Structured output schemas** (`structuredContent`) for priority tools: `opengrok_search_code`, `opengrok_get_file_content`, `opengrok_list_projects`, `opengrok_batch_search`, `opengrok_get_symbol_context`. Programmatic clients receive typed data alongside text.
|
|
123
|
+
- **`response_format` parameter** on all 14 tools: `"markdown"` (default, LLM-optimised) or `"json"` (programmatic). Shared `formatResponse()` helper eliminates per-handler duplication.
|
|
124
|
+
- **Expanded tool descriptions** for compound tools (`opengrok_batch_search`, `opengrok_search_and_read`, `opengrok_get_symbol_context`, `opengrok_get_compile_info`, `opengrok_get_file_symbols`) with "when to use / when not to use", Args, and Example sections.
|
|
125
|
+
- **Output Zod schemas** in `models.ts`: `SearchResultsOutput`, `FileContentOutput`, `ProjectsListOutput`, `BatchSearchOutput`, `SymbolContextOutput` with pagination fields (`hasMore`, `nextOffset`).
|
|
126
|
+
|
|
127
|
+
### Security
|
|
128
|
+
|
|
129
|
+
- **Logger credential redaction**: `sanitizeMeta()` in `logger.ts` strips Basic auth, Bearer tokens, URL-embedded credentials, and filesystem paths from all log output.
|
|
130
|
+
- **Complete HTML entity decoding**: `stripHtmlTags()` now handles decimal (`<`) and hex (`<`) numeric references, plus missing named entities (`nbsp`, `apos`).
|
|
131
|
+
- **Strengthened path traversal validation**: `assertSafePath()` rejects URL-encoded (`%2e%2e`, `%2f..`), double-encoded (`%252e`), and null-byte (`\0`, `%00`, `%2500`) traversal variants with decode-before-validate.
|
|
132
|
+
- **Deterministic cache keys**: `search()` cache uses `[...projects].sort().join(",")` instead of `JSON.stringify()`.
|
|
133
|
+
- **Plaintext HTTP warning**: `runServer()` logs warning when credentials are configured with `http://` base URL.
|
|
134
|
+
|
|
135
|
+
### Changed
|
|
136
|
+
|
|
137
|
+
- **ESLint strict preset**: `tseslint.configs.strict` with `no-explicit-any: "error"`, `no-floating-promises`, `await-thenable`, `no-misused-promises`.
|
|
138
|
+
- **TypeScript declarations**: `tsconfig.json` enables `declaration` and `declarationMap`. `package.json` exports `types` field.
|
|
139
|
+
- **Coverage thresholds**: `vitest.config.ts` enforces 90% lines/functions/statements, 85% branches.
|
|
140
|
+
- **Structured logging**: ISO timestamps, `[INFO]`/`[WARN]`/`[ERROR]`/`[DEBUG]` prefixes, debug level gated by `OPENGROK_LOG_LEVEL`.
|
|
141
|
+
- **Expanded language map**: Added `.tsx`, `.jsx`, `.vue`, `.scala`, `.gradle`, `.dart`, `.zig`, `.lua`, `.r`, `.m`, `.mm`, `.pl`, `.tf`, `.toml`, `.ini`, `.proto`.
|
|
142
|
+
- **npm scripts**: Added `typecheck`, `lint:fix`, `validate`.
|
|
143
|
+
- **Magic numbers extracted**: `MAX_REDIRECTS`, `MAX_FILTER_LENGTH`, `TIMEOUTS` as named constants.
|
|
144
|
+
- **Non-null assertions eliminated**: All `.pop()!` replaced with `?? ""` fallback.
|
|
145
|
+
- **Regex patterns extracted**: `LINE_ANCHOR_RE`, `DEF_SYMBOL_RE`, `SIG_RE` as module-level constants.
|
|
146
|
+
|
|
147
|
+
---
|
|
148
|
+
|
|
26
149
|
## [3.3.5] - 2026-03-15
|
|
27
150
|
|
|
28
151
|
### Changed
|
|
29
152
|
|
|
30
153
|
- **Rebrand**: Extension `displayName` renamed to **OpenGrok MCP Server**.
|
|
31
|
-
- **Description**: Updated to "MCP server bridging OpenGrok search
|
|
154
|
+
- **Description**: Updated to "MCP server bridging OpenGrok search engine with AI for deep, instant context across massive codebases" across `package.json`, `server.json`, and `README.md`.
|
|
32
155
|
- **License**: Added `LICENSE-COMMERCIAL.md` clearly describing commercial/enterprise licensing terms. Updated `LICENSE` Required Notice with author attribution. README license section now explicitly states commercial use restrictions with contact info.
|
|
33
|
-
- **Installation docs**: README now lists npm (`npx opengrok-mcp-server`) and MCP Registry (`io.github.IcyHot09/opengrok`) as first-class installation options alongside VS Code Marketplace.
|
|
156
|
+
- **Installation docs**: README now lists npm (`npx opengrok-mcp-server`) and MCP Registry (`io.github.IcyHot09/opengrok-mcp-server`) as first-class installation options alongside VS Code Marketplace.
|
|
34
157
|
- **MCP Registry badge**: Added to README header badges.
|
|
35
158
|
- **Release tooling**: Fixed wrong GitHub repo URL in `generate-release-notes.js`. Release script now syncs `server.json` version on each release.
|
|
36
159
|
|
|
@@ -66,7 +189,7 @@ Native MCP integration, OS keychain credentials, 8 OpenGrok tools, SSRF protecti
|
|
|
66
189
|
|
|
67
190
|
### Fixed
|
|
68
191
|
|
|
69
|
-
- **`get_file_annotate` shows blame markers instead of source code on OpenGrok 1.7.x**: In the real 1.7.x annotate HTML format, source code lines appear as sibling nodes *after* `<span class="blame">`, not inside it. The performance refactor in v3.3.0 introduced a regression: `el.text` on the blame span returned the blame anchor text (`
|
|
192
|
+
- **`get_file_annotate` shows blame markers instead of source code on OpenGrok 1.7.x**: In the real 1.7.x annotate HTML format, source code lines appear as sibling nodes *after* `<span class="blame">`, not inside it. The performance refactor in v3.3.0 introduced a regression: `el.text` on the blame span returned the blame anchor text (`851c8156SJane Doe`) instead of the actual source line. Fixed with index-based parent `childNodes` iteration (since `TextNode.nextSibling` is unreliable in `node-html-parser`). Also added `content` assertions to the OpenGrok 1.7.x annotate parser test.
|
|
70
193
|
|
|
71
194
|
---
|
|
72
195
|
|
package/CONTRIBUTING.md
CHANGED
|
@@ -3,40 +3,40 @@
|
|
|
3
3
|
## Project Structure
|
|
4
4
|
|
|
5
5
|
```
|
|
6
|
-
|
|
6
|
+
opengrok-mcp-server/
|
|
7
7
|
βββ src/
|
|
8
8
|
β βββ extension.ts # VS Code extension entry point
|
|
9
9
|
β βββ server/ # MCP Server (TypeScript)
|
|
10
10
|
β β βββ main.ts # Server entry point
|
|
11
|
-
β β βββ server.ts #
|
|
12
|
-
β β βββ
|
|
13
|
-
β β βββ
|
|
14
|
-
β β βββ
|
|
15
|
-
β β βββ
|
|
16
|
-
β β βββ
|
|
17
|
-
β β βββ
|
|
18
|
-
β β βββ logger.ts # Structured logging
|
|
11
|
+
β β βββ server.ts # McpServer with registerTool() per tool
|
|
12
|
+
β β βββ client.ts # OpenGrok HTTP client + caching
|
|
13
|
+
β β βββ config.ts # Environment config (Zod-validated)
|
|
14
|
+
β β βββ models.ts # Zod input/output schemas + interfaces
|
|
15
|
+
β β βββ parsers.ts # HTML response parsers
|
|
16
|
+
β β βββ formatters.ts # Compact markdown formatters
|
|
17
|
+
β β βββ logger.ts # Structured stderr logging
|
|
19
18
|
β β βββ local/
|
|
20
|
-
β β βββ compile-info.ts #
|
|
21
|
-
β βββ tests/ # Unit tests (Vitest,
|
|
19
|
+
β β βββ compile-info.ts # compile_commands.json index
|
|
20
|
+
β βββ tests/ # Unit tests (Vitest, 500+ tests)
|
|
22
21
|
β β βββ parsers.test.ts
|
|
23
22
|
β β βββ formatters.test.ts
|
|
24
23
|
β β βββ client.test.ts
|
|
25
24
|
β β βββ server.test.ts
|
|
26
|
-
β β βββ fixtures/html.ts # HTML fixture
|
|
25
|
+
β β βββ fixtures/html.ts # HTML fixture data
|
|
27
26
|
β β βββ local/
|
|
28
27
|
β β βββ compile-info.test.ts
|
|
29
28
|
β βββ webview/
|
|
30
|
-
β βββ configManager.html #
|
|
29
|
+
β βββ configManager.html # Settings webview panel
|
|
31
30
|
βββ package.json
|
|
31
|
+
βββ server.json # MCP Registry metadata
|
|
32
32
|
βββ tsconfig.json
|
|
33
|
-
βββ esbuild.js #
|
|
34
|
-
βββ eslint.config.mjs # ESLint flat config
|
|
35
|
-
βββ vitest.config.ts
|
|
33
|
+
βββ esbuild.js # Dual-target build (extension + server)
|
|
34
|
+
βββ eslint.config.mjs # ESLint strict flat config
|
|
35
|
+
βββ vitest.config.ts # Test runner + coverage thresholds
|
|
36
36
|
βββ scripts/
|
|
37
|
-
βββ release.ps1 #
|
|
37
|
+
βββ release.ps1 # Release automation
|
|
38
38
|
βββ build-vsix.js
|
|
39
|
-
βββ package-server.js #
|
|
39
|
+
βββ package-server.js # Platform archive builder
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
---
|
|
@@ -98,7 +98,7 @@ User (Copilot Chat)
|
|
|
98
98
|
| Zod 4 for config + validation | Type-safe parsing of env vars and tool args |
|
|
99
99
|
| `p-retry` for retries | Configurable exponential backoff |
|
|
100
100
|
| TTL cache with byte budget | Prevents OOM from large file caching |
|
|
101
|
-
| Compound tools (`
|
|
101
|
+
| Compound tools (`opengrok_get_symbol_context`, `opengrok_search_and_read`, `opengrok_batch_search`) | Collapse multi-step patterns into a single call β ~75β92% token savings |
|
|
102
102
|
| HTML fallback parsing | Gracefully handle OpenGrok instances where REST API is disabled |
|
|
103
103
|
| 16 KB response cap | Prevents blowing up Copilot's context window |
|
|
104
104
|
|
|
@@ -112,22 +112,33 @@ User (Copilot Chat)
|
|
|
112
112
|
export const MyNewToolArgs = z.object({
|
|
113
113
|
param1: z.string().min(1),
|
|
114
114
|
param2: z.number().int().default(10),
|
|
115
|
+
response_format: RESPONSE_FORMAT,
|
|
115
116
|
});
|
|
116
117
|
```
|
|
117
118
|
|
|
118
|
-
2. **
|
|
119
|
-
|
|
120
|
-
3. **Add dispatch case** in `dispatchTool()` in `src/server/server.ts`:
|
|
119
|
+
2. **Register the tool** via `server.registerTool()` in `src/server/server.ts`:
|
|
121
120
|
|
|
122
121
|
```typescript
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
122
|
+
server.registerTool(
|
|
123
|
+
"opengrok_my_new_tool",
|
|
124
|
+
{
|
|
125
|
+
title: "My New Tool",
|
|
126
|
+
description: "Description of what this tool does.",
|
|
127
|
+
inputSchema: MyNewToolArgs.shape,
|
|
128
|
+
annotations: READ_ONLY_OPEN,
|
|
129
|
+
},
|
|
130
|
+
async (args) => {
|
|
131
|
+
try {
|
|
132
|
+
const result = await client.myMethod(args.param1, args.param2);
|
|
133
|
+
return { content: [{ type: "text", text: capResponse(formatMyResult(result)) }] };
|
|
134
|
+
} catch (err) {
|
|
135
|
+
return makeToolError("opengrok_my_new_tool", err);
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
);
|
|
128
139
|
```
|
|
129
140
|
|
|
130
|
-
|
|
141
|
+
3. **Add client method** in `src/server/client.ts`:
|
|
131
142
|
|
|
132
143
|
```typescript
|
|
133
144
|
async myMethod(param1: string, param2: number): Promise<MyType> {
|
|
@@ -138,9 +149,9 @@ async myMethod(param1: string, param2: number): Promise<MyType> {
|
|
|
138
149
|
}
|
|
139
150
|
```
|
|
140
151
|
|
|
141
|
-
|
|
152
|
+
4. **Add formatter** in `src/server/formatters.ts` for the Markdown output
|
|
142
153
|
|
|
143
|
-
|
|
154
|
+
5. **Add unit tests** in `src/tests/`
|
|
144
155
|
|
|
145
156
|
---
|
|
146
157
|
|
package/MCP_CLIENTS.md
CHANGED
|
@@ -199,7 +199,7 @@ Build the server yourself:
|
|
|
199
199
|
|
|
200
200
|
```bash
|
|
201
201
|
git clone https://github.com/IcyHot09/opengrok-mcp-server.git
|
|
202
|
-
cd
|
|
202
|
+
cd opengrok-mcp-server
|
|
203
203
|
npm install
|
|
204
204
|
npm run compile
|
|
205
205
|
```
|
|
@@ -224,7 +224,7 @@ Config file: `~/Library/Application Support/Claude/claude_desktop_config.json` (
|
|
|
224
224
|
"mcpServers": {
|
|
225
225
|
"opengrok": {
|
|
226
226
|
"command": "node",
|
|
227
|
-
"args": ["/absolute/path/to/
|
|
227
|
+
"args": ["/absolute/path/to/opengrok-mcp-server/out/server/main.js"],
|
|
228
228
|
"env": {
|
|
229
229
|
"OPENGROK_BASE_URL": "https://opengrok.example.com/source/",
|
|
230
230
|
"OPENGROK_USERNAME": "your-username",
|
|
@@ -247,7 +247,7 @@ Claude Code supports `${VAR}` expansion in env blocks. Set `OPENGROK_PASSWORD` i
|
|
|
247
247
|
"mcpServers": {
|
|
248
248
|
"opengrok": {
|
|
249
249
|
"command": "node",
|
|
250
|
-
"args": ["/absolute/path/to/
|
|
250
|
+
"args": ["/absolute/path/to/opengrok-mcp-server/out/server/main.js"],
|
|
251
251
|
"env": {
|
|
252
252
|
"OPENGROK_BASE_URL": "https://opengrok.example.com/source/",
|
|
253
253
|
"OPENGROK_USERNAME": "your-username",
|
|
@@ -268,7 +268,7 @@ Edit `.cursor/mcp.json` in your project root or open **Cursor Settings β Featu
|
|
|
268
268
|
"mcpServers": {
|
|
269
269
|
"opengrok": {
|
|
270
270
|
"command": "node",
|
|
271
|
-
"args": ["/absolute/path/to/
|
|
271
|
+
"args": ["/absolute/path/to/opengrok-mcp-server/out/server/main.js"],
|
|
272
272
|
"env": {
|
|
273
273
|
"OPENGROK_BASE_URL": "https://opengrok.example.com/source/",
|
|
274
274
|
"OPENGROK_USERNAME": "your-username",
|
|
@@ -289,7 +289,7 @@ Config: `opencode.json` / `opencode.jsonc` in project root or `~/.config/opencod
|
|
|
289
289
|
"mcp": {
|
|
290
290
|
"opengrok": {
|
|
291
291
|
"type": "local",
|
|
292
|
-
"command": ["node", "/absolute/path/to/
|
|
292
|
+
"command": ["node", "/absolute/path/to/opengrok-mcp-server/out/server/main.js"],
|
|
293
293
|
"environment": {
|
|
294
294
|
"OPENGROK_BASE_URL": "https://opengrok.example.com/source/",
|
|
295
295
|
"OPENGROK_USERNAME": "your-username",
|
|
@@ -309,7 +309,7 @@ Use the MCP Store β *Manage MCP Servers* β *View raw config* and add:
|
|
|
309
309
|
"mcpServers": {
|
|
310
310
|
"opengrok": {
|
|
311
311
|
"command": "node",
|
|
312
|
-
"args": ["/path/to/
|
|
312
|
+
"args": ["/path/to/opengrok-mcp-server/out/server/main.js"],
|
|
313
313
|
"env": {
|
|
314
314
|
"OPENGROK_BASE_URL": "https://opengrok.example.com/source/",
|
|
315
315
|
"OPENGROK_USERNAME": "your-username",
|