@corbat-tech/coco 2.28.4 → 2.28.5

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
@@ -19280,6 +19280,24 @@ async function writeVersion(cwd, versionFile, newVersion) {
19280
19280
  return;
19281
19281
  }
19282
19282
  await writeFile(fullPath, updated, "utf-8");
19283
+ if (versionFile.stack === "node" && versionFile.path === "package.json") {
19284
+ await syncCompanionNodeVersions(cwd, newVersion);
19285
+ }
19286
+ }
19287
+ async function syncCompanionNodeVersions(cwd, newVersion) {
19288
+ for (const relativePath of NODE_VERSION_SYNC_TARGETS) {
19289
+ const fullPath = path39__default.join(cwd, relativePath);
19290
+ if (!await fileExists3(fullPath)) {
19291
+ continue;
19292
+ }
19293
+ const content = await readFile(fullPath, "utf-8");
19294
+ const pkg = JSON.parse(content);
19295
+ if (typeof pkg["version"] !== "string") {
19296
+ continue;
19297
+ }
19298
+ pkg["version"] = newVersion;
19299
+ await writeFile(fullPath, JSON.stringify(pkg, null, 2) + "\n", "utf-8");
19300
+ }
19283
19301
  }
19284
19302
  function detectBumpFromCommits(commitMessages) {
19285
19303
  let bump = "patch";
@@ -19294,7 +19312,7 @@ function detectBumpFromCommits(commitMessages) {
19294
19312
  }
19295
19313
  return bump;
19296
19314
  }
19297
- var VERSION_FILES;
19315
+ var VERSION_FILES, NODE_VERSION_SYNC_TARGETS;
19298
19316
  var init_version_detector = __esm({
19299
19317
  "src/cli/repl/skills/builtin/ship/version-detector.ts"() {
19300
19318
  init_files();
@@ -19304,6 +19322,7 @@ var init_version_detector = __esm({
19304
19322
  { file: "pyproject.toml", stack: "python", field: "version" },
19305
19323
  { file: "pom.xml", stack: "java", field: "version" }
19306
19324
  ];
19325
+ NODE_VERSION_SYNC_TARGETS = ["vscode-extension/package.json"];
19307
19326
  }
19308
19327
  });
19309
19328
  async function detectChangelog(cwd) {