Skip to content

Commit f5d23ef

Browse files
authoredJul 20, 2023
fix: add back missing createLazyProductionDeps that was missed during revert (#7679)
1 parent 441da40 commit f5d23ef

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed
 

‎.changeset/lazy-buttons-invent.md

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"app-builder-lib": patch
3+
"electron-builder": patch
4+
---
5+
6+
fix: add back missing `createLazyProductionDeps` that was missed during revert

‎packages/app-builder-lib/src/util/yarn.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ function isRunningYarn(execPath: string | null | undefined) {
153153

154154
export interface RebuildOptions {
155155
frameworkInfo: DesktopFrameworkInfo
156-
productionDeps?: Lazy<Array<NodeModuleDirInfo>>
156+
productionDeps: Lazy<Array<NodeModuleDirInfo>>
157157

158158
platform?: NodeJS.Platform
159159
arch?: string
@@ -166,7 +166,7 @@ export interface RebuildOptions {
166166
/** @internal */
167167
export async function rebuild(appDir: string, options: RebuildOptions) {
168168
const configuration: any = {
169-
dependencies: await options.productionDeps!.value,
169+
dependencies: await options.productionDeps.value,
170170
nodeExecPath: process.execPath,
171171
platform: options.platform || process.platform,
172172
arch: options.arch || process.arch,

‎packages/electron-builder/src/cli/install-app-deps.ts

+2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { getElectronVersion } from "app-builder-lib/out/electron/electronVersion
44
import { computeDefaultAppDirectory, getConfig } from "app-builder-lib/out/util/config"
55
import { installOrRebuild } from "app-builder-lib/out/util/yarn"
66
import { PACKAGE_VERSION } from "app-builder-lib/out/version"
7+
import { createLazyProductionDeps } from "app-builder-lib/src/util/packageDependencies"
78
import { getArchCliNames, log, use } from "builder-util"
89
import { printErrorAndExit } from "builder-util/out/promise"
910
import { readJson } from "fs-extra"
@@ -62,6 +63,7 @@ export async function installAppDeps(args: any) {
6263
frameworkInfo: { version, useCustomDist: true },
6364
platform: args.platform,
6465
arch: args.arch,
66+
productionDeps: createLazyProductionDeps(appDir, null),
6567
},
6668
appDir !== projectDir
6769
)

0 commit comments

Comments
 (0)
Please sign in to comment.