@clipboard-health/ai-rules 2.14.17 → 2.14.19

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/scripts/sync.js +3 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clipboard-health/ai-rules",
3
- "version": "2.14.17",
3
+ "version": "2.14.19",
4
4
  "description": "Pre-built AI agent rules for consistent coding standards.",
5
5
  "keywords": [
6
6
  "ai",
package/scripts/sync.js CHANGED
@@ -105,7 +105,7 @@ function printUsageAndExit() {
105
105
  }
106
106
  function resolveRuleIds(parsedArguments) {
107
107
  const { profile, extraIncludes, excludes } = parsedArguments;
108
- const profileRules = constants_1.PROFILES[profile].include.flatMap((category) => [...constants_1.CATEGORIES[category]]);
108
+ const profileRules = constants_1.PROFILES[profile].include.flatMap((category) => constants_1.CATEGORIES[category]);
109
109
  const ruleSet = new Set([...profileRules, ...extraIncludes]);
110
110
  for (const ruleId of excludes) {
111
111
  ruleSet.delete(ruleId);
@@ -205,7 +205,7 @@ async function mergeSessionStartHook() {
205
205
  // commands that may share the same entry. Drop entries left with no hooks.
206
206
  const cleaned = sessionStart.flatMap((entry) => {
207
207
  const entryHooks = entry["hooks"];
208
- if (!entryHooks?.some((h) => isKnownCommand(h))) {
208
+ if (entryHooks?.some((h) => isKnownCommand(h)) !== true) {
209
209
  return [entry];
210
210
  }
211
211
  const remaining = entryHooks.filter((h) => !isKnownCommand(h));
@@ -214,7 +214,7 @@ async function mergeSessionStartHook() {
214
214
  const updatedSessionStart = [...cleaned, setupHook];
215
215
  const updatedHooks = { ...hooks, SessionStart: updatedSessionStart };
216
216
  const updatedSettings = { ...settings, hooks: updatedHooks };
217
- await (0, promises_1.writeFile)(settingsPath, JSON.stringify(updatedSettings, undefined, 2) + "\n", "utf8");
217
+ await (0, promises_1.writeFile)(settingsPath, `${JSON.stringify(updatedSettings, undefined, 2)}\n`, "utf8");
218
218
  const action = hasStale || currentCount > 1 ? "Updated" : "Added";
219
219
  console.log(`📋 ${action} SessionStart hook in .claude/settings.json`);
220
220
  }