Skip to main content
Glama
Bigsy

clj-kondo MCP Server

by Bigsy

clj-kondo MCP 服务器npm 版本

一个模型上下文协议 (MCP) 服务器,为 Clojure/ClojureScript/EDN 文件提供 clj-kondo linting 功能。对于没有内置 linting 功能的 Claude 代码和桌面环境来说,这非常方便。您可以考虑编辑 CLAUDE.md 文件,并在编辑后启用 lint 功能。

特征

  • 通过 MCP 工具调用对 Clojure 文件进行 Lint

  • 支持所有 clj-kondo 分析功能

  • 可选的显式配置目录支持

Related MCP server: shadow-cljs-mcp

安装

快速安装

npx clj-kondo-mcp

或 IDE 配置

{
  "mcpServers": {
    "clj-kondo": {
      "command": "npx",
      "args": ["clj-kondo-mcp"],
      "disabled": false,
      "autoApprove": []
    }
  }
}

手动安装

  1. 安装 clj-kondo:确保已安装clj-kondo并将其添加到系统 PATH 中。请参阅适用于您平台的安装说明

  2. 安装依赖项:

npm install
  1. 构建服务器:

npm run build

用法

运行服务器

node build/index.js

MCP 工具调用

服务器提供了一个工具:

lint_clojure - Lint Clojure/ClojureScript/EDN 内容

参数:

{
  "file": "/absolute/path/to/file.clj", // Must be absolute path - can be a file, directory, or classpath
  "configDir": "/absolute/path/to/config/dir", // Optional, must be absolute path if provided
  "level": "warning" // Optional, defaults to error level
}

file参数接受:

  • 单个文件路径(例如“/path/to/src/my_file.clj”)

  • 目录路径(例如“/path/to/src”) - 将递归地检查所有 .clj、.cljs 和 .cljc 文件

  • 类路径字符串 - 将检查类路径中的所有 Clojure 文件

    • 对于 Leiningen 项目:使用lein classpath的输出

    • 对于 deps.edn 项目:使用clojure -Spath的输出

注意:由于 MCP 服务器作为独立进程运行,因此 file 和 configDir 参数都必须为绝对路径。相对路径将无法正常工作。

默认情况下,clj-kondo 会自动在当前目录及其父目录的.clj-kondo目录中查找配置。您可以通过指定configDir参数来指向特定的配置目录,从而覆盖此设置。

有关 clj-kondo 配置的更多信息,请参阅官方文档

配置

添加到您的 MCP 设置文件(对于 Cline,位于~/Library/Application Support/Code - Insiders/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json ):

{
  "mcpServers": {
    "clj-kondo": {
      "command": "npx",
      "args": ["clj-kondo-mcp"],
      "disabled": false,
      "autoApprove": []
    }
  }
}

对于手动构建,请使用:

{
  "mcpServers": {
    "clj-kondo": {
      "command": "node",
      "args": ["build/index.js"],
      "disabled": false,
      "autoApprove": []
    }
  }
}

建造

npm run build

观看模式

npm run dev
Install Server
A
license - permissive license
A
quality
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    A custom Model Context Protocol server that gives Claude Desktop and other LLMs access to file system operations and command execution capabilities through standardized tool interfaces.
    23
    Apache 2.0
  • A
    license
    A
    quality
    D
    maintenance
    A Model Context Protocol server that monitors shadow-cljs builds and provides real-time build status updates for ClojureScript projects, allowing LLMs to verify build status after making code changes.
    1
    15
    3
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A production-ready Model Context Protocol server that provides comprehensive file system management capabilities for seamless integration with Claude Desktop.
    1
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A Model Context Protocol server that analyzes application codebases with real-time file watching, providing AI assistants like Claude with deep insights into project structure, code patterns, and architecture.
    MIT

View all related MCP servers

Related MCP Connectors

  • A Model Context Protocol server for Wix AI tools

  • A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…

  • MEOK AGENTS.md Linter MCP — validates the cross-vendor coding-agent spec (Cursor / Claude Code /

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Bigsy/clj-kondo-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server