@infinitedusky/indusk-mcp 1.9.1 → 1.9.2

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.
@@ -17,18 +17,21 @@ function run(cmd, options) {
17
17
  return "";
18
18
  }
19
19
  }
20
- function ensureGitignoreMcpJson(projectRoot) {
20
+ function ensureGitignore(projectRoot) {
21
21
  const gitignorePath = join(projectRoot, ".gitignore");
22
+ const entries = ["# MCP config (contains auth tokens)", ".mcp.json"];
22
23
  if (existsSync(gitignorePath)) {
23
24
  const content = readFileSync(gitignorePath, "utf-8");
24
- if (content.includes(".mcp.json"))
25
+ if (content.includes(".mcp.json")) {
26
+ console.info(" skip: .gitignore (.mcp.json already ignored)");
25
27
  return;
26
- writeFileSync(gitignorePath, `${content.trimEnd()}\n\n# MCP config (contains auth tokens)\n.mcp.json\n`);
28
+ }
29
+ writeFileSync(gitignorePath, `${content.trimEnd()}\n\n${entries.join("\n")}\n`);
27
30
  console.info(" updated: .gitignore (added .mcp.json)");
28
31
  }
29
32
  else {
30
- writeFileSync(gitignorePath, "# MCP config (contains auth tokens)\n.mcp.json\n");
31
- console.info(" created: .gitignore (with .mcp.json)");
33
+ writeFileSync(gitignorePath, `${entries.join("\n")}\n`);
34
+ console.info(" create: .gitignore (with .mcp.json)");
32
35
  }
33
36
  }
34
37
  function createCgcIgnore(projectRoot) {
@@ -664,13 +667,12 @@ export async function init(projectRoot, options = {}) {
664
667
  }
665
668
  // 8. Create .cgcignore and manage git excludes
666
669
  createCgcIgnore(projectRoot);
670
+ // .mcp.json contains auth tokens — always gitignore it regardless of mode
671
+ ensureGitignore(projectRoot);
667
672
  if (local) {
668
673
  console.info("\n[Git Excludes]");
669
674
  writeGitInfoExclude(projectRoot);
670
675
  }
671
- else {
672
- ensureGitignoreMcpJson(projectRoot);
673
- }
674
676
  // 9. Run on_init hooks from enabled extensions
675
677
  console.info("\n[Extension Hooks]");
676
678
  const { getEnabledExtensions } = await import("../../lib/extension-loader.js");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infinitedusky/indusk-mcp",
3
- "version": "1.9.1",
3
+ "version": "1.9.2",
4
4
  "description": "InDusk development system — skills, MCP tools, and CLI for structured AI-assisted development",
5
5
  "type": "module",
6
6
  "files": [