@ucdjs/release-scripts 0.1.0-beta.21 → 0.1.0-beta.22
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.mjs +10 -4
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1289,6 +1289,10 @@ async function selectVersionPrompt(workspaceRoot, pkg, currentVersion, suggested
|
|
|
1289
1289
|
value: "suggested",
|
|
1290
1290
|
title: `suggested ${farver.bold(suggestedVersion)}`
|
|
1291
1291
|
},
|
|
1292
|
+
{
|
|
1293
|
+
value: "as-is",
|
|
1294
|
+
title: `as-is ${farver.dim("(keep current version)")}`
|
|
1295
|
+
},
|
|
1292
1296
|
{
|
|
1293
1297
|
value: "custom",
|
|
1294
1298
|
title: "custom"
|
|
@@ -1311,7 +1315,8 @@ async function selectVersionPrompt(workspaceRoot, pkg, currentVersion, suggested
|
|
|
1311
1315
|
else if (answers.version === "custom") {
|
|
1312
1316
|
if (!answers.custom) return null;
|
|
1313
1317
|
return answers.custom;
|
|
1314
|
-
} else
|
|
1318
|
+
} else if (answers.version === "as-is") return currentVersion;
|
|
1319
|
+
else return getNextVersion(pkg.version, answers.version);
|
|
1315
1320
|
}
|
|
1316
1321
|
|
|
1317
1322
|
//#endregion
|
|
@@ -1688,7 +1693,7 @@ async function verify(options) {
|
|
|
1688
1693
|
logger.info(`Found release PR #${releasePr.number}. Verifying against default branch "${defaultBranch}"...`);
|
|
1689
1694
|
const originalBranch = await getCurrentBranch(workspaceRoot);
|
|
1690
1695
|
if (originalBranch !== defaultBranch) await checkoutBranch(defaultBranch, workspaceRoot);
|
|
1691
|
-
const overridesPath =
|
|
1696
|
+
const overridesPath = ucdjsReleaseOverridesPath;
|
|
1692
1697
|
let existingOverrides = {};
|
|
1693
1698
|
try {
|
|
1694
1699
|
const overridesContent = await readFileFromGit(workspaceRoot, releasePr.head.sha, overridesPath);
|
|
@@ -1712,7 +1717,7 @@ async function verify(options) {
|
|
|
1712
1717
|
const expectedVersionMap = new Map(expectedUpdates.map((u) => [u.package.name, u.newVersion]));
|
|
1713
1718
|
const prVersionMap = /* @__PURE__ */ new Map();
|
|
1714
1719
|
for (const pkg of mainPackages) {
|
|
1715
|
-
const pkgJsonPath = join(pkg.path
|
|
1720
|
+
const pkgJsonPath = relative(workspaceRoot, join(pkg.path, "package.json"));
|
|
1716
1721
|
const pkgJsonContent = await readFileFromGit(workspaceRoot, releasePr.head.sha, pkgJsonPath);
|
|
1717
1722
|
if (pkgJsonContent) {
|
|
1718
1723
|
const pkgJson = JSON.parse(pkgJsonContent);
|
|
@@ -1746,7 +1751,8 @@ async function verify(options) {
|
|
|
1746
1751
|
sha: releasePr.head.sha,
|
|
1747
1752
|
state: "success",
|
|
1748
1753
|
context: statusContext,
|
|
1749
|
-
description: "Release PR is up to date."
|
|
1754
|
+
description: "Release PR is up to date.",
|
|
1755
|
+
targetUrl: `https://github.com/${normalizedOptions.owner}/${normalizedOptions.repo}/pull/${releasePr.number}`
|
|
1750
1756
|
});
|
|
1751
1757
|
logger.success("Verification successful. Commit status set to 'success'.");
|
|
1752
1758
|
}
|