@smbcloud / cli / commits / 761660c

Match pnpm by file stem and note why CI=true is not used

Co-Authored-By: siGit Code <noreply@sigit.si>

Seto Elkahfi committed Sep 30, 2026 at 07:32 UTC 761660c3403e4312eb37f04eab4ab9a02237d542
1 file changed +6 -1
crates/cli/src/cloud-deploy/process_deploy_nextjs_ssr.rs
+6 -1
@@ -220,7 +220,12 @@ pub async fn process_deploy_nextjs_ssr(env: Environment, config: Config) -> Resu
220 // With stdio captured pnpm has no TTY, so when it needs to recreate
221 // node_modules (store or linker change) it aborts with
222 // ERR_PNPM_ABORTED_REMOVE_MODULES_DIR_NO_TTY instead of prompting.
223 - if package_manager == "pnpm" {
223 + // CI=true would also skip the prompt, but it turns on --frozen-lockfile.
224 + // Matching on the file stem also catches full paths and Windows `pnpm.cmd`.
225 + let is_pnpm = std::path::Path::new(package_manager)
226 + .file_stem()
227 + .is_some_and(|stem| stem.eq_ignore_ascii_case("pnpm"));
228 + if is_pnpm {
229 install_command.arg("--config.confirm-modules-purge=false");
230 }
231 let install_output = install_command.current_dir(source).output().map_err(|e| {