@infinitedusky/indusk-mcp 1.11.5 → 1.11.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.
@@ -663,19 +663,17 @@ export async function init(projectRoot, options = {}) {
663
663
  for (const [event, entries] of Object.entries(hookConfig)) {
664
664
  const existingEntries = existing.hooks[event] || [];
665
665
  // Check if our hook is already present
666
- const hasOurHook = existingEntries.some((e) => e.hooks?.some((h) => h.command?.includes("check-gates") ||
667
- h.command?.includes("gate-reminder") ||
668
- h.command?.includes("validate-impl") ||
669
- h.command?.includes("check-catchup")));
670
- if (!hasOurHook || force) {
671
- // Remove old entries if force, then add
672
- if (force) {
673
- existing.hooks[event] = existingEntries.filter((e) => !e.hooks?.some((h) => h.command?.includes("check-gates") ||
674
- h.command?.includes("gate-reminder") ||
675
- h.command?.includes("validate-impl")));
666
+ // Check each hook entry individually so new hooks get added even if old ones exist
667
+ for (const entry of entries) {
668
+ const alreadyPresent = existingEntries.some((e) => e.matcher === entry.matcher &&
669
+ entry.hooks.every((newHook) => e.hooks?.some((h) => h.command === newHook.command)));
670
+ if (!alreadyPresent || force) {
671
+ if (force) {
672
+ existing.hooks[event] = (existing.hooks[event] || []).filter((e) => e.matcher !== entry.matcher);
673
+ }
674
+ existing.hooks[event] = [...(existing.hooks[event] || []), entry];
675
+ hooksUpdated = true;
676
676
  }
677
- existing.hooks[event] = [...(existing.hooks[event] || []), ...entries];
678
- hooksUpdated = true;
679
677
  }
680
678
  }
681
679
  if (hooksUpdated || permissionsUpdated) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infinitedusky/indusk-mcp",
3
- "version": "1.11.5",
3
+ "version": "1.11.6",
4
4
  "description": "InDusk development system — skills, MCP tools, and CLI for structured AI-assisted development",
5
5
  "type": "module",
6
6
  "files": [