Skip to content

fxjs/cbm-tool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cbm

Cross-platform convenience wrapper for the codebase-memory-mcp index_repository command.

Supports Linux, macOS, and Windows (PowerShell).

What it does

cbm makes it easy to index a local git repository into the codebase-memory-mcp knowledge graph, with sensible defaults and a friendlier CLI.

It also includes a setup command that configures local AI editors (Claude Code, Cursor, Codex CLI, Cline, Windsurf) to use codebase-memory-mcp and to prefer the knowledge graph when exploring code.

Project Layout

cbm-tool/
├── bin/
│   ├── cbm              # Linux / macOS entrypoint (Bash)
│   └── cbm.ps1          # Windows entrypoint (PowerShell)
├── install/
│   ├── install.sh       # Linux / macOS installer
│   └── install.ps1      # Windows installer
├── docs/
│   ├── USAGE.md         # Command reference and examples
│   ├── USAGE.zh-CN.md   # 中文使用指南
│   ├── INSTALL.md       # Per-OS installation instructions
│   └── INSTALL.zh-CN.md # 中文安装说明
├── tests/
│   ├── test_unix.sh     # Linux / macOS tests
│   └── test_windows.ps1 # Windows tests
├── Makefile             # Linux / macOS convenience targets
├── share/
│   └── cbm/
│       └── rules/
│           └── codebase-memory.md  # Default rule template
├── README.md
└── LICENSE

Quick Start

Linux / macOS

make install
cbm .

Windows

.\install\install.ps1
cbm.ps1 .

Configure your AI editors

# Auto-detect installed editors and configure them
cbm setup

# Preview changes without applying
cbm setup --dry-run

# Configure a specific editor
cbm setup --editor cursor

# Remove configuration
cbm setup --uninstall

The rule template lives at share/cbm/rules/codebase-memory.md. Pass a custom version with cbm setup --rules-file ./my-rules.md.

Update cbm or codebase-memory-mcp

# Update cbm itself from GitHub
cbm update self

# Preview the self-update
cbm update self --dry-run

# Update codebase-memory-mcp
cbm update codebase-memory-mcp

See docs/INSTALL.md for detailed installation steps and docs/USAGE.md for the full command reference.

中文文档:README.zh-CN.md | 安装指南 | 使用指南

Development

# Run Unix tests
make test

# Lint shell scripts (requires shellcheck)
make lint

On Windows, run the PowerShell tests with:

.\tests\test_windows.ps1

License

MIT

About

Cross-platform convenience wrapper for codebase-memory-mcp

Resources

License

Stars

1 star

Watchers

0 watching

Forks

Packages

 
 
 

Contributors