Skip to content

Commit ac9ed81

Browse files
authored
Merge branch 'main' into fix/windows-search-code-utf8-paths
2 parents 7e28558 + ee68144 commit ac9ed81

3 files changed

Lines changed: 18 additions & 4 deletions

File tree

README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,14 @@ The `install` command auto-detects all installed coding agents and configures MC
104104

105105
### Graph Visualization UI
106106

107-
If you downloaded the `ui` variant:
107+
The UI ships as a separate `ui` build (it embeds the frontend). The default install on every channel is the lean, headless server; opt into the UI build with:
108+
109+
- **install.sh:** add `--ui` (see [Quick Start](#quick-start))
110+
- **npm:** `CBM_VARIANT=ui npm install -g codebase-memory-mcp`
111+
- **PyPI:** `CBM_VARIANT=ui pip install codebase-memory-mcp`
112+
- **Manual:** download the `codebase-memory-mcp-ui-<os>-<arch>` archive
113+
114+
Then run it:
108115

109116
```bash
110117
codebase-memory-mcp --ui=true --port=9749

pkg/npm/install.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,14 @@ async function main() {
109109
// dynamically links glibc 2.38+ and fails on older distros. macOS/Windows
110110
// have no such variant. Keep in sync with install.sh / pypi _cli.py / cli.c.
111111
const variant = platform === 'linux' ? '-portable' : '';
112-
const archive = `codebase-memory-mcp-${platform}-${arch}${variant}.${ext}`;
112+
// Opt into the UI build (embedded graph visualization) with CBM_VARIANT=ui.
113+
// Default is the standard (headless) build. Mirrors install.sh --ui.
114+
const ui = (process.env.CBM_VARIANT || '').toLowerCase() === 'ui' ? 'ui-' : '';
115+
const archive = `codebase-memory-mcp-${ui}${platform}-${arch}${variant}.${ext}`;
113116
const url = `https://github.com/${REPO}/releases/download/v${VERSION}/${archive}`;
114117

115-
process.stdout.write(`codebase-memory-mcp: downloading v${VERSION} for ${platform}/${arch}...\n`);
118+
const uiLabel = ui ? '(ui) ' : '';
119+
process.stdout.write(`codebase-memory-mcp: downloading v${VERSION} ${uiLabel}for ${platform}/${arch}...\n`);
116120

117121
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'cbm-install-'));
118122
const tmpArchive = path.join(tmpDir, `cbm.${ext}`);

pkg/pypi/src/codebase_memory_mcp/_cli.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,10 @@ def _download(version: str) -> Path:
157157
# dynamically links glibc 2.38+ and fails on older distros. macOS/Windows
158158
# have no such variant. Keep in sync with install.sh / install.js / cli.c.
159159
variant = "-portable" if os_name == "linux" else ""
160-
archive = f"codebase-memory-mcp-{os_name}-{arch}{variant}.{ext}"
160+
# Opt into the UI build (embedded graph visualization) with CBM_VARIANT=ui.
161+
# Default is the standard (headless) build. Mirrors install.sh --ui.
162+
ui = "ui-" if os.environ.get("CBM_VARIANT", "").lower() == "ui" else ""
163+
archive = f"codebase-memory-mcp-{ui}{os_name}-{arch}{variant}.{ext}"
161164
url = f"https://github.com/{REPO}/releases/download/v{version}/{archive}"
162165
_validate_url_scheme(url)
163166

0 commit comments

Comments
 (0)