Standalone MCP server for scc code metrics. Runs on Babashka via the modex-bb framework.
Provides 4 tools for code metrics: project analysis, complexity hotspots, per-file metrics, and directory comparison.
bb --config bb.edn run server
Add to ~/.claude/settings.json:
{
"mcpServers": {
"scc": {
"command": "bb",
"args": ["--config", "/path/to/scc-mcp/bb.edn", "run", "server"]
}
}
}
| Tool | Description |
|---|---|
analyze | Project metrics — LOC, complexity, language breakdown |
hotspots | Complexity hotspots — files exceeding a threshold (default: 20) |
file | Detailed metrics for a single file |
compare | Compare metrics between two directories (diff LOC, code, complexity) |
scc-mcp implements the IAddon protocol for dynamic registration in hive-mcp. When loaded as an addon, its handlers override the embedded scc handlers in the consolidated analysis tool.
(require '[scc-mcp.init :as init])
(init/init-as-addon!)
;; => {:registered ["scc"] :total 1}
The addon exposes a single scc supertool with command dispatch:
(require '[scc-mcp.tools :as tools])
(tools/handle-scc {:command "analyze" :path "src/"})
src/scc_mcp/
core.clj — Shell wrapper for scc binary, JSON parsing, hotspot extraction
tools.clj — Command handlers + MCP tool schema (IAddon interface)
init.clj — IAddon reify + nil-railway registration pipeline
server.clj — modex-bb standalone MCP server (4 tools)
log.clj — Logging shim (timbre on JVM, stderr on bb)
MIT
Can you improve this documentation?Edit on GitHub
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |