Skip to content

Commit 2e0328d

Browse files
committed
refactor(cli): remove empty yarn.lock workaround
--no-immutable via --no-frozen-lockfile handles yarn's hardened mode, making the empty yarn.lock creation unnecessary.
1 parent e69dbb7 commit 2e0328d

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

packages/cli/src/migration/migrator.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1126,14 +1126,6 @@ function rewriteYarnrcYml(projectPath: string): void {
11261126
// catalog
11271127
rewriteCatalog(doc);
11281128
});
1129-
1130-
// Ensure yarn.lock exists so yarn install can update it in CI.
1131-
// Yarn Berry's hardened mode on public PRs forbids lockfile *creation*
1132-
// but allows *updating* an existing one.
1133-
const yarnLockPath = path.join(projectPath, 'yarn.lock');
1134-
if (!fs.existsSync(yarnLockPath)) {
1135-
fs.writeFileSync(yarnLockPath, '');
1136-
}
11371129
}
11381130

11391131
/**

0 commit comments

Comments
 (0)