rulesync 7.17.0 → 7.18.1

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
@@ -65,7 +65,7 @@ import {
65
65
  removeTempDirectory,
66
66
  stringifyFrontmatter,
67
67
  writeFileContent
68
- } from "../chunk-ZQUEAGJI.js";
68
+ } from "../chunk-JP3BFD7L.js";
69
69
 
70
70
  // src/cli/index.ts
71
71
  import { Command } from "commander";
@@ -2110,12 +2110,13 @@ async function writeSkillAndComputeIntegrity(params) {
2110
2110
  return { integrity };
2111
2111
  }
2112
2112
  function buildLockUpdate(params) {
2113
- const { lock, sourceKey, fetchedSkills, locked, requestedRef, resolvedSha } = params;
2113
+ const { lock, sourceKey, fetchedSkills, locked, requestedRef, resolvedSha, remoteSkillNames } = params;
2114
2114
  const fetchedNames = Object.keys(fetchedSkills);
2115
+ const remoteSet = new Set(remoteSkillNames);
2115
2116
  const mergedSkills = { ...fetchedSkills };
2116
2117
  if (locked) {
2117
2118
  for (const [skillName, skillEntry] of Object.entries(locked.skills)) {
2118
- if (!(skillName in mergedSkills)) {
2119
+ if (!(skillName in mergedSkills) && remoteSet.has(skillName)) {
2119
2120
  mergedSkills[skillName] = skillEntry;
2120
2121
  }
2121
2122
  }
@@ -2239,7 +2240,8 @@ async function fetchSource(params) {
2239
2240
  fetchedSkills,
2240
2241
  locked,
2241
2242
  requestedRef,
2242
- resolvedSha
2243
+ resolvedSha,
2244
+ remoteSkillNames: filteredDirs.map((d) => d.name)
2243
2245
  });
2244
2246
  return {
2245
2247
  skillCount: result.fetchedNames.length,
@@ -2327,7 +2329,8 @@ async function fetchSourceViaGit(params) {
2327
2329
  fetchedSkills,
2328
2330
  locked,
2329
2331
  requestedRef,
2330
- resolvedSha
2332
+ resolvedSha,
2333
+ remoteSkillNames: filteredNames
2331
2334
  });
2332
2335
  return {
2333
2336
  skillCount: result.fetchedNames.length,
@@ -4149,7 +4152,7 @@ async function updateCommand(currentVersion, options) {
4149
4152
  }
4150
4153
 
4151
4154
  // src/cli/index.ts
4152
- var getVersion = () => "7.17.0";
4155
+ var getVersion = () => "7.18.1";
4153
4156
  var main = async () => {
4154
4157
  const program = new Command();
4155
4158
  const version = getVersion();