chore: add no-frozen-lockfile flag for templates script (#12394)

This commit is contained in:
Paul
2025-05-13 07:15:38 -07:00
committed by GitHub
parent d9c0c43154
commit 735d699804

View File

@@ -152,6 +152,7 @@ async function main() {
generateLockfile: true, generateLockfile: true,
sharp: true, sharp: true,
skipConfig: true, // Do not copy the payload.config.ts file from the base template skipConfig: true, // Do not copy the payload.config.ts file from the base template
skipReadme: true, // Do not copy the README.md file from the base template
storage: 'localDisk', storage: 'localDisk',
// The blank template is used as a base for create-payload-app functionality, // The blank template is used as a base for create-payload-app functionality,
// so we do not configure the payload.config.ts file, which leaves the placeholder comments. // so we do not configure the payload.config.ts file, which leaves the placeholder comments.
@@ -262,10 +263,10 @@ async function main() {
if (generateLockfile) { if (generateLockfile) {
log('Generating pnpm-lock.yaml') log('Generating pnpm-lock.yaml')
execSyncSafe(`pnpm install --ignore-workspace`, { cwd: destDir }) execSyncSafe(`pnpm install --ignore-workspace --no-frozen-lockfile`, { cwd: destDir })
} else { } else {
log('Installing dependencies without generating lockfile') log('Installing dependencies without generating lockfile')
execSyncSafe(`pnpm install --ignore-workspace`, { cwd: destDir }) execSyncSafe(`pnpm install --ignore-workspace --no-frozen-lockfile`, { cwd: destDir })
await fs.rm(`${destDir}/pnpm-lock.yaml`, { force: true }) await fs.rm(`${destDir}/pnpm-lock.yaml`, { force: true })
} }