Skip to content

Commit 82c1b82

Browse files
committed
fix(cli): pass --no-frozen-lockfile to vp install in CI
Yarn Berry defaults to enableImmutableInstalls in CI, preventing lockfile creation. Pass --no-frozen-lockfile when CI env is set so vp create can generate fresh lockfiles.
1 parent 909ff6a commit 82c1b82

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

packages/cli/src/utils/prompts.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,10 @@ export async function runViteInstall(
7373
const spinner = options?.silent ? getSilentSpinner() : getSpinner(interactive);
7474
const startTime = Date.now();
7575
spinner.start(`Installing dependencies...`);
76+
const ciArgs = process.env.CI ? ['--no-frozen-lockfile'] : [];
7677
const { exitCode, stderr, stdout } = await runCommandSilently({
7778
command: process.env.VP_CLI_BIN ?? 'vp',
78-
args: ['install', ...(extraArgs ?? [])],
79+
args: ['install', ...ciArgs, ...(extraArgs ?? [])],
7980
cwd,
8081
envs: process.env,
8182
});

0 commit comments

Comments
 (0)