-
Notifications
You must be signed in to change notification settings - Fork 4
Quick Start
Get CKB running in under a minute with npm or Homebrew, or build from source if you prefer.
Works on macOS, Linux, and Windows. Requires Node.js 16+ (download).
# Install globally
npm install -g @tastehub/ckb
# Or run directly without installing
npx @tastehub/ckb --helpbrew tap SimplyLiz/ckb
brew install ckbRequires Go 1.21+.
git clone https://github.com/SimplyLiz/CodeMCP.git
cd CodeMCP
go build -o ckb ./cmd/ckbcd /path/to/your/project
# Initialize CKB
ckb init # or: npx @tastehub/ckb init
# Generate code index (auto-detects language)
ckb index # or: npx @tastehub/ckb index
# Verify it works
ckb status# Auto-configure (creates .mcp.json)
ckb setup
# Or for global config (all projects)
ckb setup --globalThat's it! Claude Code now has access to CKB's code intelligence tools.
If you prefer to build from source or need to modify CKB.
Open Terminal and run:
# Install Homebrew if you don't have it
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# Install Go
brew install go# Clone the repository
git clone https://github.com/SimplyLiz/CodeMCP.git
cd CodeMCP
# Build CKB
go build -o ckb ./cmd/ckb
# Make it available everywhere (optional)
sudo cp ckb /usr/local/bin/Navigate to your code project and run:
cd /path/to/your/project
# Initialize CKB
ckb init# Install the Go indexer
go install github.com/sourcegraph/scip-go/cmd/scip-go@latest
# Generate the index
~/go/bin/scip-go --repository-root=.ckb statusYou should see output showing your backends and symbol count.
Open Terminal and run:
# Update package list
sudo apt update
# Install Go
sudo apt install -y golang-go
# Or install latest Go manually:
wget https://go.dev/dl/go1.21.5.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.21.5.linux-amd64.tar.gz
echo 'export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin' >> ~/.bashrc
source ~/.bashrcsudo apt install -y git# Clone the repository
git clone https://github.com/SimplyLiz/CodeMCP.git
cd CodeMCP
# Build CKB
go build -o ckb ./cmd/ckb
# Make it available everywhere (optional)
sudo cp ckb /usr/local/bin/Navigate to your code project and run:
cd /path/to/your/project
# Initialize CKB
ckb init# Install the Go indexer
go install github.com/sourcegraph/scip-go/cmd/scip-go@latest
# Generate the index
~/go/bin/scip-go --repository-root=.ckb status- Download Go from: https://go.dev/dl/
- Run the installer (e.g.,
go1.21.5.windows-amd64.msi) - Click "Next" through the installer
- Restart your terminal/PowerShell after installation
- Download Git from: https://git-scm.com/download/win
- Run the installer
- Use default options (click "Next" through everything)
- Restart your terminal/PowerShell after installation
Open PowerShell and run:
# Clone the repository
git clone https://github.com/SimplyLiz/CodeMCP.git
cd CodeMCP
# Build CKB
go build -o ckb.exe ./cmd/ckb# Create a bin folder in your home directory
mkdir $HOME\bin -Force
# Copy CKB there
cp ckb.exe $HOME\bin\
# Add to PATH (run this once)
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";$HOME\bin", "User")Restart PowerShell for the PATH change to take effect.
Navigate to your code project and run:
cd C:\path\to\your\project
# Initialize CKB
ckb init# Install the Go indexer
go install github.com/sourcegraph/scip-go/cmd/scip-go@latest
# Generate the index
& "$HOME\go\bin\scip-go.exe" --repository-root=.ckb statusOnce set up, here are the essential commands:
ckb search MyFunction # Find symbols by name
ckb refs MyFunction # Find where a symbol is used
ckb status # Check system status
ckb arch # Get architecture overview
ckb doctor # Run diagnosticsSee the User Guide for the full command reference including ownership, decisions, federation, and 40+ other commands.
CKB integrates with AI coding tools via MCP (Model Context Protocol). This section covers Claude Code; see MCP Integration for Cursor, Windsurf, VS Code, Grok, and others.
# If you installed via npm:
ckb setup # project-level config
ckb setup --global # user-level config for all projects
# Or with npx:
npx @tastehub/ckb setupThis automatically creates the correct configuration.
If you prefer manual setup, add to .mcp.json in your project:
Using npm/npx (recommended):
{
"mcpServers": {
"ckb": {
"command": "npx",
"args": ["@tastehub/ckb", "mcp"]
}
}
}With a specific preset (v7.4):
{
"mcpServers": {
"ckb": {
"command": "npx",
"args": ["@tastehub/ckb", "mcp", "--preset=review"]
}
}
}Available presets: core (default, 14 tools), review, refactor, docs, ops, federation, full (80+ tools). See Presets for details.
Using local binary (build from source):
{
"mcpServers": {
"ckb": {
"command": "/path/to/ckb",
"args": ["mcp"]
}
}
}You don't need to run ckb mcp manually. Claude Code automatically spawns the MCP server as a subprocess based on your configuration. The server auto-detects your repository from the project directory.
Close and reopen Claude Code (or your AI tool). CKB tools will now be available.
For other tools, use ckb setup --tool=<name> where name is cursor, windsurf, vscode, opencode, grok, or claude-desktop.
If you want to access CKB via HTTP:
# Start the server
ckb serve --port 8080
# In another terminal, test it:
curl http://localhost:8080/healthIf installed via npm:
- Try:
npx @tastehub/ckb status - Or reinstall:
npm install -g @tastehub/ckb
If built from source:
- Use the full path:
/path/to/ckb status - Or add it to your PATH (see build instructions above)
CKB works without a SCIP index (fast mode), but for standard analysis with precise references:
# Easiest: let CKB auto-detect and run the indexer
ckb index
# Or manually for Go projects:
go install github.com/sourcegraph/scip-go/cmd/scip-go@latest
~/go/bin/scip-go --repository-root=.On macOS/Linux, you may need to make CKB executable:
chmod +x ckbRestart your terminal, or run:
# macOS/Linux
source ~/.bashrc # or ~/.zshrc
# Windows: Close and reopen PowerShell# See all commands
ckb --help
# Get help for a specific command
ckb search --help- Read the User Guide for the full CLI command reference
- See Language Support for SCIP indexers and what features each language gets
- Check the API Reference for HTTP API usage
- See MCP Integration for detailed setup with Claude Code, Cursor, Windsurf, and other tools
- Use
ckb repocommands to manage multiple repositories (see User Guide#ckb-repo) - Run
ckb refreshweekly to keep ownership and hotspot data fresh (see User Guide#keep-ownership-data-fresh) - Run
ckb doctorto diagnose any issues