Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ng-dev/release/publish/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ export abstract class ReleaseAction {
/** Installs all Yarn dependencies in the current branch. */
protected async installDependenciesForCurrentBranch() {
if (await this.pnpmVersioning.isUsingPnpm(this.projectDir)) {
await ExternalCommands.invokePnpmInstall(this.projectDir, this.pnpmVersioning);
await ExternalCommands.invokePnpmInstall(this.projectDir);
return;
}

Expand Down
22 changes: 14 additions & 8 deletions ng-dev/release/publish/external-commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -239,15 +239,21 @@ export abstract class ExternalCommands {
* Invokes the `pnpm install` command in order to install dependencies for
* the configured project with the currently checked out revision.
*/
static async invokePnpmInstall(
projectDir: string,
pnpmVersioning: PnpmVersioning,
): Promise<void> {
static async invokePnpmInstall(projectDir: string): Promise<void> {
try {
const pnpmSpec = await pnpmVersioning.getPackageSpec(projectDir);
await ChildProcess.spawn('npx', ['--yes', pnpmSpec, 'install', '--frozen-lockfile'], {
cwd: projectDir,
});
await ChildProcess.spawn(
'pnpm',
[
'install',
'--frozen-lockfile',
// PNPM does not have no interactive,
// See: https://github.com/pnpm/pnpm/issues/6778
'--config.confirmModulesPurge=false',
],
{
cwd: projectDir,
},
);

Log.info(green(' ✓ Installed project dependencies.'));
} catch (e) {
Expand Down