@lintsure/mcp 0.3.13 → 0.3.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/src/index.js +5 -4
- package/package.json +54 -51
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @lintsure/mcp
|
|
2
2
|
|
|
3
|
-
Lintsure as an MCP server for Claude Code, Cursor, Codex, Devin Desktop (formerly Windsurf) and other MCP clients. Runs on your machine over stdio, never writes files, never uploads your code.
|
|
3
|
+
**Keep your AI coding agents on track.** Lintsure as an MCP server for Claude Code, Cursor, Codex, Devin Desktop (formerly Windsurf) and other MCP clients: the agent asks which checks apply before it writes code, and scans its own work before it says it is done. Runs on your machine over stdio, never writes files, never uploads your code.
|
|
4
4
|
|
|
5
5
|
> **Lintsure is a readiness tool, not an audit, a certification or legal advice.** It tells your coding agent not to call you compliant, certified or ready, not to decide for you, and to ask before changing anything. A person makes the final call.
|
|
6
6
|
|
|
@@ -8,7 +8,7 @@ Lintsure as an MCP server for Claude Code, Cursor, Codex, Devin Desktop (formerl
|
|
|
8
8
|
claude mcp add lintsure -- npx -y @lintsure/mcp
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
Then ask your agent: *check this repo for
|
|
11
|
+
Then ask your agent: *check this repo for security problems*.
|
|
12
12
|
|
|
13
13
|
Tools: `scan`, `plan_checks`, `classify`, `explain_framework`, `explain_rule`. Setup for Cursor, Codex and Devin Desktop (formerly Windsurf): https://lintsure.com/docs/mcp
|
|
14
14
|
|
package/dist/src/index.js
CHANGED
|
@@ -6,8 +6,8 @@ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
|
6
6
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
7
7
|
import { resolve } from "node:path";
|
|
8
8
|
import { z } from "zod";
|
|
9
|
-
import { AGENT_GUIDANCE, APPROVAL_RULES, TRIAGE_GUIDE, ALL_FRAMEWORKS, DISCLAIMER, checksFor, classify, getKnowledge, nextSteps, readConfig, rules, scan, toMarkdown } from "@lintsure/core";
|
|
10
|
-
const server = new McpServer({ name: "lintsure", version: "0.3.
|
|
9
|
+
import { AGENT_GUIDANCE, APPROVAL_RULES, TRIAGE_GUIDE, ALL_FRAMEWORKS, DISCLAIMER, checksFor, classify, getKnowledge, isHygiene, nextSteps, readConfig, rules, scan, toMarkdown } from "@lintsure/core";
|
|
10
|
+
const server = new McpServer({ name: "lintsure", version: "0.3.15" }, { instructions: AGENT_GUIDANCE });
|
|
11
11
|
// Every tool only reads. Clients can show this; none of them may treat a Lintsure tool as making changes.
|
|
12
12
|
const RO = { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false };
|
|
13
13
|
// Checked in the handler, not a startup enum, so frameworks from a repo's rule packs are accepted too.
|
|
@@ -42,11 +42,12 @@ server.tool("scan", "Scan a repository's source code for compliance and security
|
|
|
42
42
|
const scope = files?.map(norm);
|
|
43
43
|
const picked = report.findings.filter((f) => (!scope || scope.some((p) => f.file === p || f.file.startsWith(p + "/")))
|
|
44
44
|
&& (!only || only.includes(f.ruleId)) && (status === "all" || f.status === status) && !(f.accepted && !f.accepted.expired));
|
|
45
|
-
const rank = (f) => (f.status === "gap" ? 0 : 3) + { high: 0, medium: 1, low: 2 }[f.severity];
|
|
45
|
+
const rank = (f) => (isHygiene(f) ? 6 : 0) + (f.status === "gap" ? 0 : 3) + { high: 0, medium: 1, low: 2 }[f.severity] + (f.reach?.status === "unreachable" ? 0.5 : 0);
|
|
46
46
|
const shown = [...picked].sort((a, b) => rank(a) - rank(b)).slice(0, limit);
|
|
47
47
|
const gaps = picked.filter((f) => f.status === "gap").length;
|
|
48
|
+
const hygiene = picked.filter(isHygiene).length; // sorted last, so the limit drops these first
|
|
48
49
|
return reply([
|
|
49
|
-
`Lintsure ${report.rulesVersion}: ${picked.length} open finding${picked.length === 1 ? "" : "s"} (${gaps} gap, ${picked.length - gaps} partial)${scope || only ? " in the files and rules asked for" : ""}, ${report.filesChecked} files read.`,
|
|
50
|
+
`Lintsure ${report.rulesVersion}: ${picked.length} open finding${picked.length === 1 ? "" : "s"} (${gaps} gap, ${picked.length - gaps} partial${hygiene && hygiene < picked.length ? `; ${hygiene} are repo hygiene, listed last` : ""})${scope || only ? " in the files and rules asked for" : ""}, ${report.filesChecked} files read${report.filesSkipped ? `, ${report.filesSkipped} skipped (over 1 MB, binary or unreadable)` : ""}.`,
|
|
50
51
|
...(picked.length > shown.length ? [`Showing the first ${shown.length}; raise limit or narrow with files to see more.`] : []),
|
|
51
52
|
"",
|
|
52
53
|
...shown.map((f) => `- ${f.id} ${f.status === "gap" ? "Gap" : "Partial"} · ${f.severity} · ${f.file}:${f.line} · ${f.ruleId}: ${f.title}. Fix: ${f.fix}`),
|
package/package.json
CHANGED
|
@@ -1,51 +1,54 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@lintsure/mcp",
|
|
3
|
-
"version": "0.3.
|
|
4
|
-
"mcpName": "io.github.lintsure/lintsure",
|
|
5
|
-
"description": "Lintsure MCP server
|
|
6
|
-
"license": "Apache-2.0",
|
|
7
|
-
"type": "module",
|
|
8
|
-
"bin": {
|
|
9
|
-
"lintsure-mcp": "dist/src/index.js"
|
|
10
|
-
},
|
|
11
|
-
"files": [
|
|
12
|
-
"dist/src",
|
|
13
|
-
"README.md",
|
|
14
|
-
"LICENSE"
|
|
15
|
-
],
|
|
16
|
-
"dependencies": {
|
|
17
|
-
"@lintsure/core": "0.3.
|
|
18
|
-
"@modelcontextprotocol/sdk": "^1.12.0",
|
|
19
|
-
"zod": "^4.6.7"
|
|
20
|
-
},
|
|
21
|
-
"author": "Lintsure <hello@lintsure.com>",
|
|
22
|
-
"homepage": "https://lintsure.com/docs",
|
|
23
|
-
"repository": {
|
|
24
|
-
"type": "git",
|
|
25
|
-
"url": "git+https://github.com/lintsure/lintsure.git"
|
|
26
|
-
},
|
|
27
|
-
"bugs": {
|
|
28
|
-
"url": "https://github.com/lintsure/lintsure/issues",
|
|
29
|
-
"email": "support@lintsure.com"
|
|
30
|
-
},
|
|
31
|
-
"engines": {
|
|
32
|
-
"node": ">=22"
|
|
33
|
-
},
|
|
34
|
-
"publishConfig": {
|
|
35
|
-
"access": "public"
|
|
36
|
-
},
|
|
37
|
-
"keywords": [
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
"
|
|
46
|
-
"
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
"
|
|
50
|
-
|
|
51
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "@lintsure/mcp",
|
|
3
|
+
"version": "0.3.15",
|
|
4
|
+
"mcpName": "io.github.lintsure/lintsure",
|
|
5
|
+
"description": "Lintsure MCP server: lets Claude Code, Cursor, Codex and other agents check their own code before they say they are done. Runs locally. Not an audit or legal advice.",
|
|
6
|
+
"license": "Apache-2.0",
|
|
7
|
+
"type": "module",
|
|
8
|
+
"bin": {
|
|
9
|
+
"lintsure-mcp": "dist/src/index.js"
|
|
10
|
+
},
|
|
11
|
+
"files": [
|
|
12
|
+
"dist/src",
|
|
13
|
+
"README.md",
|
|
14
|
+
"LICENSE"
|
|
15
|
+
],
|
|
16
|
+
"dependencies": {
|
|
17
|
+
"@lintsure/core": "0.3.15",
|
|
18
|
+
"@modelcontextprotocol/sdk": "^1.12.0",
|
|
19
|
+
"zod": "^4.6.7"
|
|
20
|
+
},
|
|
21
|
+
"author": "Lintsure <hello@lintsure.com>",
|
|
22
|
+
"homepage": "https://lintsure.com/docs",
|
|
23
|
+
"repository": {
|
|
24
|
+
"type": "git",
|
|
25
|
+
"url": "git+https://github.com/lintsure/lintsure.git"
|
|
26
|
+
},
|
|
27
|
+
"bugs": {
|
|
28
|
+
"url": "https://github.com/lintsure/lintsure/issues",
|
|
29
|
+
"email": "support@lintsure.com"
|
|
30
|
+
},
|
|
31
|
+
"engines": {
|
|
32
|
+
"node": ">=22"
|
|
33
|
+
},
|
|
34
|
+
"publishConfig": {
|
|
35
|
+
"access": "public"
|
|
36
|
+
},
|
|
37
|
+
"keywords": [
|
|
38
|
+
"mcp",
|
|
39
|
+
"mcp-server",
|
|
40
|
+
"model-context-protocol",
|
|
41
|
+
"ai-agents",
|
|
42
|
+
"claude-code",
|
|
43
|
+
"cursor",
|
|
44
|
+
"codex",
|
|
45
|
+
"guardrails",
|
|
46
|
+
"security",
|
|
47
|
+
"owasp",
|
|
48
|
+
"gdpr",
|
|
49
|
+
"eu-ai-act"
|
|
50
|
+
],
|
|
51
|
+
"scripts": {
|
|
52
|
+
"prepublishOnly": "cd ../.. && npm test"
|
|
53
|
+
}
|
|
54
|
+
}
|