xtrm-cli 2.1.19 → 2.1.20

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.cjs CHANGED
@@ -41078,8 +41078,10 @@ async function getAvailableProjectSkills() {
41078
41078
  function getScriptFilename(hook) {
41079
41079
  const cmd = hook.command || hook.hooks?.[0]?.command || "";
41080
41080
  if (typeof cmd !== "string") return null;
41081
- const m = cmd.match(/([A-Za-z0-9._/-]+\.(?:py|cjs|mjs|js))(?!.*[A-Za-z0-9._/-]+\.(?:py|cjs|mjs|js))/);
41082
- return m?.[1] ?? null;
41081
+ const m = cmd.match(/\/hooks\/([A-Za-z0-9_/-]+\.(?:py|cjs|mjs|js))/);
41082
+ if (m) return m[1];
41083
+ const m2 = cmd.match(/([A-Za-z0-9_-]+\.(?:py|cjs|mjs|js))(?!.*[A-Za-z0-9._-]+\.(?:py|cjs|mjs|js))/);
41084
+ return m2?.[1] ?? null;
41083
41085
  }
41084
41086
  function pruneStaleHooks(existing, canonical) {
41085
41087
  const result = { ...existing };