nairon-bench 0.0.25 → 0.0.26
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/index.js +74 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -16138,6 +16138,14 @@ var publishCommand = defineCommand2({
|
|
|
16138
16138
|
process.exit(1);
|
|
16139
16139
|
}
|
|
16140
16140
|
const repoInfo = detectRepository(projectDir);
|
|
16141
|
+
const mcpServers = detectMCPServers(projectDir);
|
|
16142
|
+
const skills = detectSkills(projectDir);
|
|
16143
|
+
if (mcpServers.length > 0) {
|
|
16144
|
+
consola.success(`Found ${mcpServers.length} MCP servers`);
|
|
16145
|
+
}
|
|
16146
|
+
if (skills.length > 0) {
|
|
16147
|
+
consola.success(`Found ${skills.length} skills`);
|
|
16148
|
+
}
|
|
16141
16149
|
consola.info(`Publishing report for ${repoInfo.name}...`);
|
|
16142
16150
|
try {
|
|
16143
16151
|
const result = await client.mutation(api.publicReports.publish, {
|
|
@@ -16159,7 +16167,9 @@ var publishCommand = defineCommand2({
|
|
|
16159
16167
|
periodStart: reports[0]?.date ?? new Date().toISOString(),
|
|
16160
16168
|
periodEnd: reports[reports.length - 1]?.date ?? new Date().toISOString(),
|
|
16161
16169
|
repositoryName: repoInfo.name,
|
|
16162
|
-
...repoInfo.url ? { repositoryUrl: repoInfo.url } : {}
|
|
16170
|
+
...repoInfo.url ? { repositoryUrl: repoInfo.url } : {},
|
|
16171
|
+
mcpServers: mcpServers.map((s2) => s2.name),
|
|
16172
|
+
skills: skills.map((s2) => s2.name)
|
|
16163
16173
|
});
|
|
16164
16174
|
consola.success(`Published! Your report is live.`);
|
|
16165
16175
|
consola.log("");
|
|
@@ -16245,9 +16255,9 @@ function detectTools(projectDir) {
|
|
|
16245
16255
|
{ name: "Windsurf", check: () => existsSync9(join9(home, ".windsurf")) },
|
|
16246
16256
|
{ name: "Aider", check: () => existsSync9(join9(projectDir, ".aider.conf.yml")) },
|
|
16247
16257
|
{ name: "Codeium", check: () => existsSync9(join9(home, ".codeium")) },
|
|
16248
|
-
{ name: "
|
|
16249
|
-
{ name: "
|
|
16250
|
-
{ name: "
|
|
16258
|
+
{ name: "Tabnine", check: () => existsSync9(join9(home, ".tabnine")) },
|
|
16259
|
+
{ name: "Amazon Q", check: () => existsSync9(join9(home, ".aws", "amazonq")) },
|
|
16260
|
+
{ name: "Beads", check: () => existsSync9(join9(projectDir, ".beads")) }
|
|
16251
16261
|
];
|
|
16252
16262
|
for (const { name, check } of toolChecks) {
|
|
16253
16263
|
try {
|
|
@@ -16258,6 +16268,65 @@ function detectTools(projectDir) {
|
|
|
16258
16268
|
}
|
|
16259
16269
|
return tools;
|
|
16260
16270
|
}
|
|
16271
|
+
function detectMCPServers(projectDir) {
|
|
16272
|
+
const servers = [];
|
|
16273
|
+
const home = homedir7();
|
|
16274
|
+
const mcpLocations = [
|
|
16275
|
+
{ path: join9(home, ".mcp.json"), source: "global" },
|
|
16276
|
+
{ path: join9(home, ".cursor", "mcp.json"), source: "Cursor" },
|
|
16277
|
+
{ path: join9(home, ".windsurf", "mcp_config.json"), source: "Windsurf" },
|
|
16278
|
+
{ path: join9(projectDir, ".mcp.json"), source: "project" },
|
|
16279
|
+
{ path: join9(projectDir, ".cursor", "mcp.json"), source: "Cursor (project)" },
|
|
16280
|
+
{ path: join9(projectDir, ".windsurf", "mcp_config.json"), source: "Windsurf (project)" }
|
|
16281
|
+
];
|
|
16282
|
+
for (const { path, source } of mcpLocations) {
|
|
16283
|
+
try {
|
|
16284
|
+
if (existsSync9(path)) {
|
|
16285
|
+
const content = readFileSync6(path, "utf-8");
|
|
16286
|
+
const config = JSON.parse(content);
|
|
16287
|
+
const mcpServers = config.mcpServers || config;
|
|
16288
|
+
if (typeof mcpServers === "object") {
|
|
16289
|
+
for (const name of Object.keys(mcpServers)) {
|
|
16290
|
+
if (!servers.some((s2) => s2.name === name)) {
|
|
16291
|
+
servers.push({ name, source });
|
|
16292
|
+
}
|
|
16293
|
+
}
|
|
16294
|
+
}
|
|
16295
|
+
}
|
|
16296
|
+
} catch {}
|
|
16297
|
+
}
|
|
16298
|
+
return servers;
|
|
16299
|
+
}
|
|
16300
|
+
function detectSkills(projectDir) {
|
|
16301
|
+
const skills = [];
|
|
16302
|
+
const home = homedir7();
|
|
16303
|
+
const skillsLocations = [
|
|
16304
|
+
{ path: join9(home, ".claude", "skills"), source: "Claude Code" },
|
|
16305
|
+
{ path: join9(home, ".cursor", "skills"), source: "Cursor" },
|
|
16306
|
+
{ path: join9(home, ".config", "opencode", "skills"), source: "OpenCode" },
|
|
16307
|
+
{ path: join9(home, ".windsurf", "skills"), source: "Windsurf" },
|
|
16308
|
+
{ path: join9(home, ".agents", "skills"), source: "Agents" },
|
|
16309
|
+
{ path: join9(home, ".config", "agents", "skills"), source: "Agents" },
|
|
16310
|
+
{ path: join9(projectDir, ".claude", "skills"), source: "Claude Code (project)" },
|
|
16311
|
+
{ path: join9(projectDir, ".cursor", "skills"), source: "Cursor (project)" }
|
|
16312
|
+
];
|
|
16313
|
+
for (const { path, source } of skillsLocations) {
|
|
16314
|
+
try {
|
|
16315
|
+
if (existsSync9(path)) {
|
|
16316
|
+
const entries = readdirSync3(path, { withFileTypes: true });
|
|
16317
|
+
for (const entry of entries) {
|
|
16318
|
+
if (entry.isDirectory() || entry.isSymbolicLink()) {
|
|
16319
|
+
const skillName = entry.name;
|
|
16320
|
+
if (!skills.some((s2) => s2.name === skillName)) {
|
|
16321
|
+
skills.push({ name: skillName, source });
|
|
16322
|
+
}
|
|
16323
|
+
}
|
|
16324
|
+
}
|
|
16325
|
+
}
|
|
16326
|
+
} catch {}
|
|
16327
|
+
}
|
|
16328
|
+
return skills;
|
|
16329
|
+
}
|
|
16261
16330
|
function aggregateReports(reports) {
|
|
16262
16331
|
if (reports.length === 0) {
|
|
16263
16332
|
return {
|
|
@@ -17727,7 +17796,7 @@ function formatBytes(bytes) {
|
|
|
17727
17796
|
// package.json
|
|
17728
17797
|
var package_default = {
|
|
17729
17798
|
name: "nairon-bench",
|
|
17730
|
-
version: "0.0.
|
|
17799
|
+
version: "0.0.26",
|
|
17731
17800
|
description: "AI workflow benchmarking CLI",
|
|
17732
17801
|
type: "module",
|
|
17733
17802
|
bin: {
|