Skip to content

Commit 3bb13f9

Browse files
authored
ci(dev): pin associated dev versions (#11238)
1 parent 06a75e8 commit 3bb13f9

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

packages/actions/src/releasePackages/generateReleaseTree.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,13 @@ async function getReleaseEntries(dry: boolean, devTag?: string) {
5858
};
5959

6060
if (devTag) {
61+
// Replace workspace dependencies with * to pin to associated dev versions
62+
const pkgJsonString = await file(`${pkg.path}/package.json`).text();
63+
pkgJsonString.replaceAll(/workspace:[\^~]/g, 'workspace:*');
64+
if (!dry) {
65+
await write(`${pkg.path}/package.json`, pkgJsonString);
66+
}
67+
6168
const devVersion = await fetchDevVersion(pkg.name, devTag);
6269
if (devVersion?.endsWith(commitHash)) {
6370
// Write the currently released dev version so when pnpm publish runs on dependents they depend on the dev versions

0 commit comments

Comments
 (0)