@pharaoh-so/mcp 0.2.5 → 0.2.6
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/dist/helpers.js +1 -1
- package/dist/inspect.js +12 -1
- package/dist/install-skills.js +4 -3
- package/package.json +1 -1
package/dist/helpers.js
CHANGED
|
@@ -40,7 +40,7 @@ export function parseArgs(argv = process.argv.slice(2)) {
|
|
|
40
40
|
return { server, logout };
|
|
41
41
|
}
|
|
42
42
|
export function printUsage() {
|
|
43
|
-
printLines("Usage: pharaoh-mcp [options]", "", "Options:", " --server <url> Pharaoh server URL (default: https://mcp.pharaoh.so)", " --logout Clear stored credentials and exit", " --install-skills
|
|
43
|
+
printLines("Usage: pharaoh-mcp [options]", "", "Options:", " --server <url> Pharaoh server URL (default: https://mcp.pharaoh.so)", " --logout Clear stored credentials and exit", " --install-skills Force reinstall Pharaoh skills (Claude Code + OpenClaw)", " --help, -h Show this help", "", "Add to Claude Code:", " claude mcp add pharaoh -- npx @pharaoh-so/mcp", "");
|
|
44
44
|
}
|
|
45
45
|
/**
|
|
46
46
|
* Validate that a server-supplied SSE URL shares the same origin as the configured server.
|
package/dist/inspect.js
CHANGED
|
@@ -14,6 +14,17 @@ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
|
14
14
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
15
15
|
const INSPECT_MSG = "This is Pharaoh's inspection server for directory listings. " +
|
|
16
16
|
"Connect to https://mcp.pharaoh.so for actual usage.";
|
|
17
|
+
/** Read version from package.json (single source of truth). */
|
|
18
|
+
function getPackageVersion() {
|
|
19
|
+
try {
|
|
20
|
+
const pkgPath = join(import.meta.dirname, "..", "package.json");
|
|
21
|
+
const pkg = JSON.parse(readFileSync(pkgPath, "utf-8"));
|
|
22
|
+
return pkg.version ?? "0.0.0";
|
|
23
|
+
}
|
|
24
|
+
catch {
|
|
25
|
+
return "0.0.0";
|
|
26
|
+
}
|
|
27
|
+
}
|
|
17
28
|
export async function runInspect() {
|
|
18
29
|
// Load pre-generated schemas (shipped in the npm package)
|
|
19
30
|
const schemasPath = join(import.meta.dirname, "..", "inspect-tools.json");
|
|
@@ -25,7 +36,7 @@ export async function runInspect() {
|
|
|
25
36
|
process.stderr.write("Pharaoh: inspect-tools.json not found — rebuild the package.\n");
|
|
26
37
|
process.exit(1);
|
|
27
38
|
}
|
|
28
|
-
const server = new McpServer({ name: "pharaoh", version:
|
|
39
|
+
const server = new McpServer({ name: "pharaoh", version: getPackageVersion() }, {
|
|
29
40
|
instructions: "Pharaoh turns codebases into knowledge graphs that AI agents can think with. " +
|
|
30
41
|
"Connect at https://mcp.pharaoh.so for full functionality.",
|
|
31
42
|
});
|
package/dist/install-skills.js
CHANGED
|
@@ -69,17 +69,18 @@ function installClaudeCodePlugin(home = homedir()) {
|
|
|
69
69
|
return -1;
|
|
70
70
|
}
|
|
71
71
|
// Copy skills/
|
|
72
|
+
let skillCount = 0;
|
|
72
73
|
if (existsSync(BUNDLED_SKILLS_DIR)) {
|
|
73
74
|
cpSync(BUNDLED_SKILLS_DIR, join(pluginDir, "skills"), { recursive: true, force: true });
|
|
75
|
+
const entries = readdirSync(BUNDLED_SKILLS_DIR, { withFileTypes: true });
|
|
76
|
+
skillCount = entries.filter((e) => e.isDirectory()).length;
|
|
74
77
|
}
|
|
75
78
|
// Copy .mcp.json
|
|
76
79
|
const mcpSrc = join(PKG_ROOT, ".mcp.json");
|
|
77
80
|
if (existsSync(mcpSrc)) {
|
|
78
81
|
cpSync(mcpSrc, join(pluginDir, ".mcp.json"), { force: true });
|
|
79
82
|
}
|
|
80
|
-
|
|
81
|
-
const entries = readdirSync(BUNDLED_SKILLS_DIR, { withFileTypes: true });
|
|
82
|
-
return entries.filter((e) => e.isDirectory()).length;
|
|
83
|
+
return skillCount;
|
|
83
84
|
}
|
|
84
85
|
/**
|
|
85
86
|
* Register Pharaoh in Claude Code's installed_plugins.json (v2 format).
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pharaoh-so/mcp",
|
|
3
3
|
"mcpName": "so.pharaoh/pharaoh",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.6",
|
|
5
5
|
"description": "MCP proxy for Pharaoh — maps codebases into queryable knowledge graphs for AI agents. Enables Claude Code in headless environments (VPS, SSH, CI) via device flow auth.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/index.js",
|