@rebasepro/cli 0.9.1-canary.ad25bc0 → 0.9.1-canary.ad870eb

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.es.js CHANGED
@@ -531,8 +531,6 @@ async function replacePlaceholders(options) {
531
531
  let cliVersion = "latest";
532
532
  if (fs.existsSync(packageJsonPath)) cliVersion = JSON.parse(fs.readFileSync(packageJsonPath, "utf-8")).version || "latest";
533
533
  const versionCache = /* @__PURE__ */ new Map();
534
- /** Packages with no release matching the CLI's own version. */
535
- const unreleased = /* @__PURE__ */ new Map();
536
534
  const viewBin = "npm";
537
535
  const getPackageVersion = async (pkgName) => {
538
536
  if (versionCache.has(pkgName)) return versionCache.get(pkgName);
@@ -570,7 +568,6 @@ async function replacePlaceholders(options) {
570
568
  versionToUse = "latest";
571
569
  }
572
570
  }
573
- if (versionToUse !== cliVersion) unreleased.set(pkgName, versionToUse);
574
571
  }
575
572
  versionCache.set(pkgName, versionToUse);
576
573
  return versionToUse;
@@ -587,12 +584,6 @@ async function replacePlaceholders(options) {
587
584
  }
588
585
  console.log(chalk.gray(" Resolving package versions..."));
589
586
  await Promise.all(Array.from(allPackages).map(getPackageVersion));
590
- const cliIsStable = cliVersion !== "latest" && !cliVersion.includes("-");
591
- const prereleasePins = [...unreleased].filter(([, version]) => version === "latest" || version.includes("-"));
592
- if (cliIsStable && prereleasePins.length > 0) {
593
- const lines = prereleasePins.map(([name, version]) => ` ${name} → ${version}`).join("\n");
594
- throw new Error(`Rebase ${cliVersion} is not fully published to npm.\n\nThese packages have no ${cliVersion} release, so the newest thing on the\nregistry is a prerelease:\n\n${lines}\n\nScaffolding would pin those alongside the ${cliVersion} packages and produce\nan app that cannot install or run. That is a release gap in Rebase itself —\nnot a problem with your machine, your network, or your package manager.\n\nStopped before writing dependency versions or installing anything. The\nproject directory ${path.basename(options.targetDirectory)}/ was created and is safe to delete.\nPlease report this with the list above.`);
595
- }
596
587
  for (const [fullPath, originalContent] of fileContents.entries()) {
597
588
  let content = originalContent.replace(/\{\{PROJECT_NAME\}\}/g, options.projectName);
598
589
  const matches = [...content.matchAll(/"(@rebasepro\/[^"]+)":\s*"workspace:\*"/g)];