aisnitch 0.2.12 → 0.2.13

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/cli/index.js CHANGED
@@ -723,7 +723,6 @@ var ANSI_RESET = "\x1B[0m";
723
723
  var ANSI_RED = "\x1B[31m";
724
724
  var ANSI_GREEN = "\x1B[32m";
725
725
  var ANSI_CYAN = "\x1B[36m";
726
- var CLAUDE_FILE_CHANGED_MATCHER = ".*";
727
726
  var CLAUDE_CODE_HOOK_EVENTS = [
728
727
  "SessionStart",
729
728
  "UserPromptSubmit",
@@ -734,15 +733,12 @@ var CLAUDE_CODE_HOOK_EVENTS = [
734
733
  "Notification",
735
734
  "SubagentStart",
736
735
  "SubagentStop",
737
- "TaskCreated",
738
736
  "TaskCompleted",
739
737
  "Stop",
740
738
  "StopFailure",
741
739
  "TeammateIdle",
742
740
  "InstructionsLoaded",
743
741
  "ConfigChange",
744
- "CwdChanged",
745
- "FileChanged",
746
742
  "WorktreeCreate",
747
743
  "WorktreeRemove",
748
744
  "PreCompact",
@@ -1733,8 +1729,7 @@ function ensureClaudeAISnitchHook(groups, hookEventName, hookUrl, scriptPath) {
1733
1729
  ...group,
1734
1730
  hooks: group.hooks.map((handler) => ({ ...handler }))
1735
1731
  }));
1736
- const matcher = hookEventName === "FileChanged" ? CLAUDE_FILE_CHANGED_MATCHER : void 0;
1737
- const matchingGroup = clonedGroups.find((group) => group.matcher === matcher);
1732
+ const matchingGroup = clonedGroups.find((group) => group.matcher === void 0);
1738
1733
  if (matchingGroup) {
1739
1734
  matchingGroup.hooks = matchingGroup.hooks.filter(
1740
1735
  (handler) => !isLegacyClaudeAISnitchHttpHook(handler, hookUrl)
@@ -1753,13 +1748,9 @@ function ensureClaudeAISnitchHook(groups, hookEventName, hookUrl, scriptPath) {
1753
1748
  );
1754
1749
  return clonedGroups;
1755
1750
  }
1756
- const nextGroup = matcher === void 0 ? {
1757
- hooks: [createClaudeAISnitchHook(hookEventName, hookUrl, scriptPath)]
1758
- } : {
1759
- matcher,
1751
+ clonedGroups.push({
1760
1752
  hooks: [createClaudeAISnitchHook(hookEventName, hookUrl, scriptPath)]
1761
- };
1762
- clonedGroups.push(nextGroup);
1753
+ });
1763
1754
  return clonedGroups;
1764
1755
  }
1765
1756
  function createClaudeAISnitchHook(hookEventName, hookUrl, scriptPath) {