@contentrain/mcp 2.3.0 → 2.3.1

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.
@@ -1,5 +1,6 @@
1
- import { a as readJson, r as pathExists } from "./fs-DLbVB-Ek.mjs";
1
+ import { a as readJson, o as readText, r as pathExists } from "./fs-DLbVB-Ek.mjs";
2
2
  import { dirname, join } from "node:path";
3
+ import { readdir } from "node:fs/promises";
3
4
  //#region src/util/detect.ts
4
5
  const STACK_META = {
5
6
  nuxt: {
@@ -179,6 +180,7 @@ async function detectStackInfo(projectRoot) {
179
180
  dir = parent;
180
181
  }
181
182
  }
183
+ if (stack === "other") stack = await detectFromWorkspaces(projectRoot);
182
184
  if (stack === "other") stack = await detectNonJs(projectRoot);
183
185
  const mono = await detectMonorepo(projectRoot);
184
186
  const features = await detectFeatures(projectRoot);
@@ -222,6 +224,95 @@ async function detectFromDeps(dir) {
222
224
  if ("node" in (pkg.dependencies ?? {})) return "node";
223
225
  return "other";
224
226
  }
227
+ /**
228
+ * Ranked by how strongly the stack determines content conventions — a
229
+ * meta-framework dictates the i18n setup and the replacement expression,
230
+ * a plain UI library does not. Frequency would be the wrong tie-break: a
231
+ * monorepo with one Next app and two React packages is a Next project.
232
+ */
233
+ const STACK_PRIORITY = [
234
+ "nuxt",
235
+ "next",
236
+ "astro",
237
+ "sveltekit",
238
+ "remix",
239
+ "analog",
240
+ "expo",
241
+ "react-native",
242
+ "vue",
243
+ "react",
244
+ "svelte",
245
+ "solid",
246
+ "angular",
247
+ "electron",
248
+ "tauri",
249
+ "nestjs",
250
+ "fastify",
251
+ "express",
252
+ "eleventy",
253
+ "node"
254
+ ];
255
+ /** Cap the fan-out so a large monorepo cannot turn detection into a crawl. */
256
+ const MAX_WORKSPACE_DIRS = 50;
257
+ /**
258
+ * Workspace globs from `pnpm-workspace.yaml` or the `workspaces` field.
259
+ *
260
+ * The pnpm file is parsed line by line rather than with a YAML library: we
261
+ * need exactly one list of strings with a fixed shape, and a parser
262
+ * dependency for that is not worth the install size.
263
+ */
264
+ async function readWorkspacePatterns(root) {
265
+ const pnpm = await readText(join(root, "pnpm-workspace.yaml"));
266
+ if (pnpm) {
267
+ const patterns = [];
268
+ let inPackages = false;
269
+ for (const raw of pnpm.split("\n")) {
270
+ const line = raw.replace(/#.*$/, "").trimEnd();
271
+ if (/^packages:\s*$/.test(line)) {
272
+ inPackages = true;
273
+ continue;
274
+ }
275
+ if (!inPackages) continue;
276
+ const item = /^\s+-\s*['"]?([^'"]+?)['"]?\s*$/.exec(line);
277
+ if (item?.[1]) {
278
+ patterns.push(item[1]);
279
+ continue;
280
+ }
281
+ if (line.trim() !== "") break;
282
+ }
283
+ if (patterns.length > 0) return patterns;
284
+ }
285
+ const ws = (await readJson(join(root, "package.json")))?.workspaces;
286
+ if (Array.isArray(ws)) return ws;
287
+ if (ws && Array.isArray(ws.packages)) return ws.packages;
288
+ return [];
289
+ }
290
+ /**
291
+ * Expand workspace patterns to directories. Only a trailing `*` segment is
292
+ * expanded — that covers `apps/*` and `packages/*`, which is what real
293
+ * workspace files use. Deeper globs and negations are skipped rather than
294
+ * half-supported.
295
+ */
296
+ async function listWorkspaceDirs(root) {
297
+ const patterns = (await readWorkspacePatterns(root)).filter((p) => !p.startsWith("!"));
298
+ return (await Promise.all(patterns.map(async (pattern) => {
299
+ const star = pattern.indexOf("*");
300
+ if (star === -1) return [join(root, pattern)];
301
+ const base = join(root, pattern.slice(0, star).replace(/\/+$/, ""));
302
+ try {
303
+ return (await readdir(base, { withFileTypes: true })).filter((e) => e.isDirectory()).map((e) => join(base, e.name));
304
+ } catch {
305
+ return [];
306
+ }
307
+ }))).flat().slice(0, MAX_WORKSPACE_DIRS);
308
+ }
309
+ /** Highest-priority stack across the workspace packages. */
310
+ async function detectFromWorkspaces(root) {
311
+ const dirs = await listWorkspaceDirs(root);
312
+ if (dirs.length === 0) return "other";
313
+ const found = new Set(await Promise.all(dirs.map((d) => detectFromDeps(d))));
314
+ return STACK_PRIORITY.find((s) => found.has(s)) ?? "other";
315
+ }
225
316
  async function detectNonJs(projectRoot) {
226
317
  if (await pathExists(join(projectRoot, "go.mod"))) return "go";
227
318
  if (await pathExists(join(projectRoot, "Cargo.toml"))) return "rust";
@@ -231,7 +322,6 @@ async function detectNonJs(projectRoot) {
231
322
  "setup.py"
232
323
  ]) if (await pathExists(join(projectRoot, f))) {
233
324
  try {
234
- const { readText } = await import("./util/fs.mjs");
235
325
  const content = await readText(join(projectRoot, f));
236
326
  if (content?.includes("django") || content?.includes("Django")) return "django";
237
327
  } catch {}
@@ -239,7 +329,6 @@ async function detectNonJs(projectRoot) {
239
329
  }
240
330
  if (await pathExists(join(projectRoot, "Gemfile"))) {
241
331
  try {
242
- const { readText } = await import("./util/fs.mjs");
243
332
  if ((await readText(join(projectRoot, "Gemfile")))?.includes("rails")) return "rails";
244
333
  } catch {}
245
334
  return "other";
@@ -257,7 +346,6 @@ async function detectNonJs(projectRoot) {
257
346
  if (await pathExists(join(projectRoot, "pubspec.yaml"))) return "flutter";
258
347
  if (await pathExists(join(projectRoot, "hugo.toml"))) return "hugo";
259
348
  if (await pathExists(join(projectRoot, "config.toml"))) try {
260
- const { readText } = await import("./util/fs.mjs");
261
349
  const content = await readText(join(projectRoot, "config.toml"));
262
350
  if (content?.includes("baseURL") || content?.includes("hugo")) return "hugo";
263
351
  } catch {}
@@ -354,9 +442,14 @@ async function collectAllDeps(projectRoot) {
354
442
  if (parent === dir) break;
355
443
  dir = parent;
356
444
  }
445
+ const workspaceDirs = await listWorkspaceDirs(projectRoot);
446
+ if (workspaceDirs.length > 0) {
447
+ const pkgs = await Promise.all(workspaceDirs.map((d) => readJson(join(d, "package.json"))));
448
+ for (const wsPkg of pkgs) if (wsPkg) Object.assign(allDeps, wsPkg.dependencies, wsPkg.devDependencies);
449
+ }
357
450
  return allDeps;
358
451
  }
359
452
  //#endregion
360
453
  export { detectStackInfo as n, inferPlatform as r, detectStack as t };
361
454
 
362
- //# sourceMappingURL=detect-wVSI9VuY.mjs.map
455
+ //# sourceMappingURL=detect-CdDU4Ew_.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"detect-CdDU4Ew_.mjs","names":[],"sources":["../src/util/detect.ts"],"sourcesContent":["import type { StackType, Platform } from '@contentrain/types'\nimport { join, dirname } from 'node:path'\nimport { readdir } from 'node:fs/promises'\nimport { readJson, pathExists, readText } from './fs.js'\n\ninterface PackageJson {\n dependencies?: Record<string, string>\n devDependencies?: Record<string, string>\n workspaces?: string[] | { packages: string[] }\n}\n\nexport interface StackInfo {\n stack: StackType\n platform: Platform\n name: string\n description: string\n monorepo: boolean\n monorepoTool?: string\n features: string[]\n}\n\nconst STACK_META: Record<StackType, { name: string; description: string }> = {\n // Meta-frameworks\n nuxt: { name: 'Nuxt', description: 'Vue meta-framework with SSR/SSG' },\n next: { name: 'Next.js', description: 'React framework with SSR/SSG' },\n astro: { name: 'Astro', description: 'Content-first web framework' },\n sveltekit: { name: 'SvelteKit', description: 'Svelte meta-framework' },\n remix: { name: 'Remix', description: 'Full-stack React framework' },\n analog: { name: 'Analog', description: 'Angular meta-framework' },\n // Plain frameworks\n vue: { name: 'Vue', description: 'Progressive JavaScript framework' },\n react: { name: 'React', description: 'UI library for web and native' },\n svelte: { name: 'Svelte', description: 'Compile-time UI framework' },\n solid: { name: 'Solid', description: 'Reactive UI library' },\n angular: { name: 'Angular', description: 'Platform for web applications' },\n // Mobile\n 'react-native': { name: 'React Native', description: 'Cross-platform mobile framework' },\n expo: { name: 'Expo', description: 'React Native toolchain' },\n flutter: { name: 'Flutter', description: 'Cross-platform UI toolkit (Dart)' },\n // Backend\n node: { name: 'Node.js', description: 'Server-side JavaScript runtime' },\n express: { name: 'Express', description: 'Minimal Node.js web framework' },\n fastify: { name: 'Fastify', description: 'Fast Node.js web framework' },\n nestjs: { name: 'NestJS', description: 'Progressive Node.js framework' },\n django: { name: 'Django', description: 'Python web framework' },\n rails: { name: 'Rails', description: 'Ruby web framework' },\n laravel: { name: 'Laravel', description: 'PHP web framework' },\n go: { name: 'Go', description: 'Go programming language' },\n rust: { name: 'Rust', description: 'Rust programming language' },\n dotnet: { name: '.NET', description: 'Microsoft .NET platform' },\n // Static\n hugo: { name: 'Hugo', description: 'Go-based static site generator' },\n jekyll: { name: 'Jekyll', description: 'Ruby-based static site generator' },\n eleventy: { name: 'Eleventy', description: 'JavaScript static site generator' },\n // Desktop\n electron: { name: 'Electron', description: 'Cross-platform desktop apps' },\n tauri: { name: 'Tauri', description: 'Lightweight desktop apps (Rust)' },\n // Catch-all\n other: { name: 'Other', description: 'Unknown or unsupported framework' },\n}\n\nexport function inferPlatform(stack: StackType): Platform {\n switch (stack) {\n case 'nuxt': case 'next': case 'astro': case 'sveltekit': case 'remix': case 'analog':\n case 'vue': case 'react': case 'svelte': case 'solid': case 'angular':\n return 'web'\n case 'react-native': case 'expo': case 'flutter':\n return 'mobile'\n case 'node': case 'express': case 'fastify': case 'nestjs':\n case 'django': case 'rails': case 'laravel': case 'go': case 'rust': case 'dotnet':\n return 'api'\n case 'electron': case 'tauri':\n return 'desktop'\n case 'hugo': case 'jekyll': case 'eleventy':\n return 'static'\n default:\n return 'other'\n }\n}\n\n/** Backward-compatible: returns just the StackType string */\nexport async function detectStack(projectRoot: string): Promise<StackType> {\n const info = await detectStackInfo(projectRoot)\n return info.stack\n}\n\n/** Rich detection: stack + platform + monorepo + features */\nexport async function detectStackInfo(projectRoot: string): Promise<StackInfo> {\n let stack = await detectFromDeps(projectRoot)\n\n // Walk up for monorepo root if local didn't match\n if (stack === 'other') {\n let dir = dirname(projectRoot)\n for (let i = 0; i < 5; i++) {\n const pkg = await readJson<PackageJson>(join(dir, 'package.json'))\n if (pkg?.workspaces) {\n const rootStack = await detectFromDeps(dir)\n if (rootStack !== 'other') {\n stack = rootStack\n break\n }\n }\n const parent = dirname(dir)\n if (parent === dir) break\n dir = parent\n }\n }\n\n // Look DOWN into the workspaces. The walk above handles \"I am inside a\n // package, find the monorepo root\"; this handles the opposite and more\n // common case — projectRoot IS the monorepo root, whose package.json holds\n // only tooling (turbo, nx) while the frameworks live in apps/* and\n // packages/*. Without this a Next.js monorepo reports `other`, and the\n // stack is what picks the replacement conventions during normalize.\n if (stack === 'other') {\n stack = await detectFromWorkspaces(projectRoot)\n }\n\n // Non-JS detection if still 'other'\n if (stack === 'other') {\n stack = await detectNonJs(projectRoot)\n }\n\n const mono = await detectMonorepo(projectRoot)\n const features = await detectFeatures(projectRoot)\n const meta = STACK_META[stack]\n\n return {\n stack,\n platform: inferPlatform(stack),\n name: meta.name,\n description: meta.description,\n monorepo: mono.isMonorepo,\n monorepoTool: mono.tool,\n features,\n }\n}\n\nasync function detectFromDeps(dir: string): Promise<StackType> {\n const pkg = await readJson<PackageJson>(join(dir, 'package.json'))\n if (!pkg) return 'other'\n\n const allDeps = { ...pkg.dependencies, ...pkg.devDependencies }\n\n // Meta-frameworks (check BEFORE plain frameworks)\n if ('nuxt' in allDeps) return 'nuxt'\n if ('next' in allDeps) return 'next'\n if ('astro' in allDeps) return 'astro'\n if ('@sveltejs/kit' in allDeps) return 'sveltekit'\n if ('@remix-run/node' in allDeps || 'remix' in allDeps) return 'remix'\n if ('@analogjs/platform' in allDeps) return 'analog'\n\n // Mobile (check before plain react)\n if ('expo' in allDeps) return 'expo'\n if ('react-native' in allDeps) return 'react-native'\n\n // Plain frameworks\n if ('vue' in allDeps) return 'vue'\n if ('svelte' in allDeps) return 'svelte'\n if ('solid-js' in allDeps) return 'solid'\n if ('@angular/core' in allDeps) return 'angular'\n if ('react' in allDeps) return 'react'\n\n // Desktop\n if ('electron' in allDeps) return 'electron'\n if ('@tauri-apps/api' in allDeps) return 'tauri'\n\n // Backend (Node.js)\n if ('@nestjs/core' in allDeps) return 'nestjs'\n if ('fastify' in allDeps) return 'fastify'\n if ('express' in allDeps) return 'express'\n\n // Static site generators\n if ('@11ty/eleventy' in allDeps) return 'eleventy'\n\n // Generic Node.js (has package.json but no framework)\n if ('node' in (pkg.dependencies ?? {})) return 'node'\n\n return 'other'\n}\n\n/**\n * Ranked by how strongly the stack determines content conventions — a\n * meta-framework dictates the i18n setup and the replacement expression,\n * a plain UI library does not. Frequency would be the wrong tie-break: a\n * monorepo with one Next app and two React packages is a Next project.\n */\nconst STACK_PRIORITY: readonly StackType[] = [\n 'nuxt', 'next', 'astro', 'sveltekit', 'remix', 'analog',\n 'expo', 'react-native',\n 'vue', 'react', 'svelte', 'solid', 'angular',\n 'electron', 'tauri',\n 'nestjs', 'fastify', 'express',\n 'eleventy', 'node',\n]\n\n/** Cap the fan-out so a large monorepo cannot turn detection into a crawl. */\nconst MAX_WORKSPACE_DIRS = 50\n\n/**\n * Workspace globs from `pnpm-workspace.yaml` or the `workspaces` field.\n *\n * The pnpm file is parsed line by line rather than with a YAML library: we\n * need exactly one list of strings with a fixed shape, and a parser\n * dependency for that is not worth the install size.\n */\nasync function readWorkspacePatterns(root: string): Promise<string[]> {\n const pnpm = await readText(join(root, 'pnpm-workspace.yaml'))\n if (pnpm) {\n const patterns: string[] = []\n let inPackages = false\n for (const raw of pnpm.split('\\n')) {\n const line = raw.replace(/#.*$/, '').trimEnd()\n if (/^packages:\\s*$/.test(line)) { inPackages = true; continue }\n if (!inPackages) continue\n const item = /^\\s+-\\s*['\"]?([^'\"]+?)['\"]?\\s*$/.exec(line)\n if (item?.[1]) { patterns.push(item[1]); continue }\n if (line.trim() !== '') break // a new top-level key ends the list\n }\n if (patterns.length > 0) return patterns\n }\n\n const pkg = await readJson<PackageJson>(join(root, 'package.json'))\n const ws = pkg?.workspaces\n if (Array.isArray(ws)) return ws\n if (ws && Array.isArray(ws.packages)) return ws.packages\n return []\n}\n\n/**\n * Expand workspace patterns to directories. Only a trailing `*` segment is\n * expanded — that covers `apps/*` and `packages/*`, which is what real\n * workspace files use. Deeper globs and negations are skipped rather than\n * half-supported.\n */\nasync function listWorkspaceDirs(root: string): Promise<string[]> {\n const patterns = (await readWorkspacePatterns(root)).filter(p => !p.startsWith('!'))\n\n const expanded = await Promise.all(patterns.map(async (pattern) => {\n const star = pattern.indexOf('*')\n if (star === -1) return [join(root, pattern)]\n const base = join(root, pattern.slice(0, star).replace(/\\/+$/, ''))\n try {\n const entries = await readdir(base, { withFileTypes: true })\n return entries.filter(e => e.isDirectory()).map(e => join(base, e.name))\n } catch {\n return []\n }\n }))\n\n return expanded.flat().slice(0, MAX_WORKSPACE_DIRS)\n}\n\n/** Highest-priority stack across the workspace packages. */\nasync function detectFromWorkspaces(root: string): Promise<StackType> {\n const dirs = await listWorkspaceDirs(root)\n if (dirs.length === 0) return 'other'\n\n const found = new Set(await Promise.all(dirs.map(d => detectFromDeps(d))))\n return STACK_PRIORITY.find(s => found.has(s)) ?? 'other'\n}\n\nasync function detectNonJs(projectRoot: string): Promise<StackType> {\n // Go\n if (await pathExists(join(projectRoot, 'go.mod'))) return 'go'\n\n // Rust\n if (await pathExists(join(projectRoot, 'Cargo.toml'))) return 'rust'\n\n // Python\n for (const f of ['requirements.txt', 'pyproject.toml', 'setup.py']) {\n if (await pathExists(join(projectRoot, f))) {\n // Check for Django\n try {\n const content = await readText(join(projectRoot, f))\n if (content?.includes('django') || content?.includes('Django')) return 'django'\n } catch { /* ignore */ }\n return 'other' // Generic Python — no specific stack type yet\n }\n }\n\n // Ruby\n if (await pathExists(join(projectRoot, 'Gemfile'))) {\n try {\n const content = await readText(join(projectRoot, 'Gemfile'))\n if (content?.includes('rails')) return 'rails'\n } catch { /* ignore */ }\n return 'other'\n }\n\n // .NET\n const dotnetFiles = ['*.csproj', '*.sln']\n for (const pattern of dotnetFiles) {\n if (pattern === '*.csproj' && await pathExists(join(projectRoot, 'Program.cs'))) return 'dotnet'\n if (pattern === '*.sln' && await pathExists(join(projectRoot, 'Program.cs'))) return 'dotnet'\n }\n\n // PHP / Laravel\n if (await pathExists(join(projectRoot, 'composer.json'))) {\n try {\n const composer = await readJson<Record<string, unknown>>(join(projectRoot, 'composer.json'))\n const require = composer?.require as Record<string, string> | undefined\n if (require?.['laravel/framework']) return 'laravel'\n } catch { /* ignore */ }\n return 'other'\n }\n\n // Flutter (Dart)\n if (await pathExists(join(projectRoot, 'pubspec.yaml'))) return 'flutter'\n\n // Hugo\n if (await pathExists(join(projectRoot, 'hugo.toml'))) return 'hugo'\n if (await pathExists(join(projectRoot, 'config.toml'))) {\n try {\n const content = await readText(join(projectRoot, 'config.toml'))\n if (content?.includes('baseURL') || content?.includes('hugo')) return 'hugo'\n } catch { /* ignore */ }\n }\n\n // Jekyll\n if (await pathExists(join(projectRoot, '_config.yml'))) return 'jekyll'\n\n return 'other'\n}\n\nasync function detectMonorepo(projectRoot: string): Promise<{ isMonorepo: boolean; tool?: string }> {\n if (await pathExists(join(projectRoot, 'pnpm-workspace.yaml'))) return { isMonorepo: true, tool: 'pnpm workspaces' }\n if (await pathExists(join(projectRoot, 'lerna.json'))) return { isMonorepo: true, tool: 'Lerna' }\n if (await pathExists(join(projectRoot, 'nx.json'))) return { isMonorepo: true, tool: 'Nx' }\n if (await pathExists(join(projectRoot, 'turbo.json'))) return { isMonorepo: true, tool: 'Turborepo' }\n\n const pkg = await readJson<PackageJson>(join(projectRoot, 'package.json'))\n if (pkg?.workspaces) return { isMonorepo: true, tool: 'npm/yarn workspaces' }\n\n // Walk up\n let dir = dirname(projectRoot)\n for (let i = 0; i < 5; i++) {\n if (await pathExists(join(dir, 'pnpm-workspace.yaml'))) return { isMonorepo: true, tool: 'pnpm workspaces' }\n if (await pathExists(join(dir, 'lerna.json'))) return { isMonorepo: true, tool: 'Lerna' }\n if (await pathExists(join(dir, 'nx.json'))) return { isMonorepo: true, tool: 'Nx' }\n if (await pathExists(join(dir, 'turbo.json'))) return { isMonorepo: true, tool: 'Turborepo' }\n const parentPkg = await readJson<PackageJson>(join(dir, 'package.json'))\n if (parentPkg?.workspaces) return { isMonorepo: true, tool: 'npm/yarn workspaces' }\n const parent = dirname(dir)\n if (parent === dir) break\n dir = parent\n }\n\n return { isMonorepo: false }\n}\n\nasync function detectFeatures(projectRoot: string): Promise<string[]> {\n const features: string[] = []\n const allDeps = await collectAllDeps(projectRoot)\n\n if ('typescript' in allDeps || await pathExists(join(projectRoot, 'tsconfig.json'))) features.push('TypeScript')\n\n const i18nLibs = ['vue-i18n', '@nuxtjs/i18n', 'next-intl', 'react-intl', 'i18next', 'react-i18next']\n for (const lib of i18nLibs) {\n if (lib in allDeps) { features.push(`i18n (${lib})`); break }\n }\n\n if ('tailwindcss' in allDeps) features.push('Tailwind CSS')\n else if ('sass' in allDeps || 'scss' in allDeps) features.push('Sass/SCSS')\n\n if ('vitest' in allDeps) features.push('Vitest')\n else if ('jest' in allDeps) features.push('Jest')\n\n if ('pinia' in allDeps) features.push('Pinia')\n else if ('zustand' in allDeps) features.push('Zustand')\n else if ('@reduxjs/toolkit' in allDeps || 'redux' in allDeps) features.push('Redux')\n\n return features\n}\n\nasync function collectAllDeps(projectRoot: string): Promise<Record<string, string>> {\n const pkg = await readJson<PackageJson>(join(projectRoot, 'package.json'))\n const allDeps: Record<string, string> = { ...pkg?.dependencies, ...pkg?.devDependencies }\n\n let dir = dirname(projectRoot)\n for (let i = 0; i < 5; i++) {\n const parentPkg = await readJson<PackageJson>(join(dir, 'package.json'))\n if (parentPkg?.workspaces) {\n Object.assign(allDeps, parentPkg.dependencies, parentPkg.devDependencies)\n break\n }\n const parent = dirname(dir)\n if (parent === dir) break\n dir = parent\n }\n\n // Same blind spot as stack detection: at a monorepo root the interesting\n // dependencies (the i18n library above all) sit in the workspace packages,\n // not in the root manifest. Reporting \"no i18n\" for a project that has it\n // would send normalize down the wrong path.\n const workspaceDirs = await listWorkspaceDirs(projectRoot)\n if (workspaceDirs.length > 0) {\n const pkgs = await Promise.all(\n workspaceDirs.map(d => readJson<PackageJson>(join(d, 'package.json'))),\n )\n for (const wsPkg of pkgs) {\n if (wsPkg) Object.assign(allDeps, wsPkg.dependencies, wsPkg.devDependencies)\n }\n }\n\n return allDeps\n}\n"],"mappings":";;;;AAqBA,MAAM,aAAuE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,UAAU,cAAc,UAAU,gBAAgB;AACzE;;EAEF,MAAM,SAAS,QAAQ,IAAI;AAC3B,MAAI,WAAW,IAAK;AACpB,QAAM;;CAOR,MAAM,gBAAgB,MAAM,kBAAkB,YAAY;AAC1D,KAAI,cAAc,SAAS,GAAG;EAC5B,MAAM,OAAO,MAAM,QAAQ,IACzB,cAAc,KAAI,MAAK,SAAsB,KAAK,GAAG,eAAe,CAAC,CAAC,CACvE;AACD,OAAK,MAAM,SAAS,KAClB,KAAI,MAAO,QAAO,OAAO,SAAS,MAAM,cAAc,MAAM,gBAAgB;;AAIhF,QAAO"}
package/dist/index.mjs CHANGED
@@ -11,9 +11,9 @@ import "./branch-lifecycle-BAfgSQBv.mjs";
11
11
  import "./id-DV_T9Ic8.mjs";
12
12
  import "./transaction-1SPznNt3.mjs";
13
13
  import "./local-8dJ5NIWL.mjs";
14
- import "./detect-wVSI9VuY.mjs";
14
+ import "./detect-CdDU4Ew_.mjs";
15
15
  import "./annotations-D3tlsF38.mjs";
16
- import { n as createServer } from "./server-I6sqKvO8.mjs";
16
+ import { n as createServer } from "./server-CUZnuHQx.mjs";
17
17
  import "./validator-ChiYk6ap.mjs";
18
18
  import "./scan-config-BlNLRCMx.mjs";
19
19
  import "./graph-builder-DK4Mh8Tn.mjs";
@@ -10,9 +10,9 @@ import "../../branch-lifecycle-BAfgSQBv.mjs";
10
10
  import "../../id-DV_T9Ic8.mjs";
11
11
  import "../../transaction-1SPznNt3.mjs";
12
12
  import "../../local-8dJ5NIWL.mjs";
13
- import "../../detect-wVSI9VuY.mjs";
13
+ import "../../detect-CdDU4Ew_.mjs";
14
14
  import "../../annotations-D3tlsF38.mjs";
15
- import { n as createServer } from "../../server-I6sqKvO8.mjs";
15
+ import { n as createServer } from "../../server-CUZnuHQx.mjs";
16
16
  import "../../validator-ChiYk6ap.mjs";
17
17
  import "../../scan-config-BlNLRCMx.mjs";
18
18
  import "../../graph-builder-DK4Mh8Tn.mjs";
@@ -9,7 +9,7 @@ import { a as deleteRemoteBranch, c as pruneMergedRemoteBranches, i as cleanupMe
9
9
  import { i as mergeBranch, n as createTransaction, r as ensureContentBranch, t as buildBranchName } from "./transaction-1SPznNt3.mjs";
10
10
  import { n as isMerged, t as LocalProvider } from "./local-8dJ5NIWL.mjs";
11
11
  import { n as isToolAvailable, t as TOOL_REQUIREMENTS } from "./availability-sWWRz2W0.mjs";
12
- import { t as detectStack } from "./detect-wVSI9VuY.mjs";
12
+ import { t as detectStack } from "./detect-CdDU4Ew_.mjs";
13
13
  import { t as TOOL_ANNOTATIONS } from "./annotations-D3tlsF38.mjs";
14
14
  import { n as listTemplates, t as getTemplate } from "./templates-D6EllixQ.mjs";
15
15
  import { n as mapProviderError } from "./errors-e0YdjooK.mjs";
@@ -2612,7 +2612,7 @@ function registerMediaTools(server, provider, _projectRoot) {
2612
2612
  }
2613
2613
  //#endregion
2614
2614
  //#region package.json
2615
- var version = "2.3.0";
2615
+ var version = "2.3.1";
2616
2616
  //#endregion
2617
2617
  //#region src/server.ts
2618
2618
  /**
@@ -2682,4 +2682,4 @@ function resolveServerContext(input) {
2682
2682
  //#endregion
2683
2683
  export { createServer as n, DEFAULT_INSTRUCTIONS as t };
2684
2684
 
2685
- //# sourceMappingURL=server-I6sqKvO8.mjs.map
2685
+ //# sourceMappingURL=server-CUZnuHQx.mjs.map