From 55c6477bcc7c9bad9f83e8347f4b042874832bf8 Mon Sep 17 00:00:00 2001 From: LongYinan Date: Thu, 23 Nov 2023 19:46:50 +0800 Subject: [PATCH] fix(electron): appimage forge builder (#5043) --- ...tron-forge-core-npm-6.4.2-ab60c87e75.patch | 13 ---- package.json | 3 +- yarn.lock | 70 ------------------- 3 files changed, 1 insertion(+), 85 deletions(-) delete mode 100644 .yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch diff --git a/.yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch b/.yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch deleted file mode 100644 index b8e0df7783..0000000000 --- a/.yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/dist/util/forge-config.js b/dist/util/forge-config.js -index 3466ac1a340c8dfe5ea8997178961e8328457d68..ceb33770db48df80e4355e6bac12e8c99162d7bc 100644 ---- a/dist/util/forge-config.js -+++ b/dist/util/forge-config.js -@@ -130,7 +130,7 @@ exports.default = async (dir) => { - try { - // The loaded "config" could potentially be a static forge config, ESM module or async function - // eslint-disable-next-line @typescript-eslint/no-var-requires -- const loaded = require(path_1.default.resolve(dir, forgeConfig)); -+ const loaded = await import(require('node:url').pathToFileURL(path_1.default.join(dir, forgeConfig))) - const maybeForgeConfig = 'default' in loaded ? loaded.default : loaded; - forgeConfig = typeof maybeForgeConfig === 'function' ? await maybeForgeConfig() : maybeForgeConfig; - } diff --git a/package.json b/package.json index e8eb2cf893..7497d27ef0 100644 --- a/package.json +++ b/package.json @@ -173,8 +173,7 @@ "which-boxed-primitive": "npm:@nolyfill/which-boxed-primitive@latest", "which-typed-array": "npm:@nolyfill/which-typed-array@latest", "next-auth@^4.24.5": "patch:next-auth@npm%3A4.24.5#~/.yarn/patches/next-auth-npm-4.24.5-8428e11927.patch", - "@electron-forge/core@^6.4.2": "patch:@electron-forge/core@npm%3A6.4.2#./.yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch", - "@electron-forge/core@6.4.2": "patch:@electron-forge/core@npm%3A6.4.2#./.yarn/patches/@electron-forge-core-npm-6.4.2-ab60c87e75.patch", + "@reforged/maker-appimage/@electron-forge/maker-base": "7.1.0", "macos-alias": "npm:macos-alias-building@latest", "fs-xattr": "npm:@napi-rs/xattr@latest" } diff --git a/yarn.lock b/yarn.lock index 37f13b0e44..8df6bcf658 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4667,17 +4667,6 @@ __metadata: languageName: node linkType: hard -"@electron-forge/maker-base@npm:^6.0.4": - version: 6.4.2 - resolution: "@electron-forge/maker-base@npm:6.4.2" - dependencies: - "@electron-forge/shared-types": "npm:6.4.2" - fs-extra: "npm:^10.0.0" - which: "npm:^2.0.2" - checksum: 4d80af9381322354a71be4f78003bb98a350c05367f70cc9e001bad6c448094d6167d7295f6ca113856c5d47be4b776d7b53a0a8dd0e511b632985419f3d5e81 - languageName: node - linkType: hard - "@electron-forge/maker-deb@npm:^7.1.0": version: 7.1.0 resolution: "@electron-forge/maker-deb@npm:7.1.0" @@ -4763,17 +4752,6 @@ __metadata: languageName: node linkType: hard -"@electron-forge/shared-types@npm:6.4.2": - version: 6.4.2 - resolution: "@electron-forge/shared-types@npm:6.4.2" - dependencies: - "@electron/rebuild": "npm:^3.2.10" - electron-packager: "npm:^17.1.2" - listr2: "npm:^5.0.3" - checksum: 063b2e2dd89cbfb2ee541fe26eaeb83836f20c6e4a0ac7f4ddafb41d9a3a4b07ab917025e469ea04894eadf639619b235bc58a358750e005b50edb5a8177ca39 - languageName: node - linkType: hard - "@electron-forge/shared-types@npm:7.1.0, @electron-forge/shared-types@npm:^7.1.0": version: 7.1.0 resolution: "@electron-forge/shared-types@npm:7.1.0" @@ -4903,16 +4881,6 @@ __metadata: languageName: node linkType: hard -"@electron/notarize@npm:^1.2.3": - version: 1.2.4 - resolution: "@electron/notarize@npm:1.2.4" - dependencies: - debug: "npm:^4.1.1" - fs-extra: "npm:^9.0.1" - checksum: c0c163d85a5ded7438e746a194571eadccb0119193056d8949cb8351801e44a3ffae31d65b4094d7b8d7a0f655117b3a217a66f4c43e380310d7992c1204d62a - languageName: node - linkType: hard - "@electron/notarize@npm:^2.1.0": version: 2.2.0 resolution: "@electron/notarize@npm:2.2.0" @@ -19580,35 +19548,6 @@ __metadata: languageName: node linkType: hard -"electron-packager@npm:^17.1.2": - version: 17.1.2 - resolution: "electron-packager@npm:17.1.2" - dependencies: - "@electron/asar": "npm:^3.2.1" - "@electron/get": "npm:^2.0.0" - "@electron/notarize": "npm:^1.2.3" - "@electron/osx-sign": "npm:^1.0.5" - "@electron/universal": "npm:^1.3.2" - cross-spawn-windows-exe: "npm:^1.2.0" - debug: "npm:^4.0.1" - extract-zip: "npm:^2.0.0" - filenamify: "npm:^4.1.0" - fs-extra: "npm:^11.1.0" - galactus: "npm:^1.0.0" - get-package-info: "npm:^1.0.0" - junk: "npm:^3.1.0" - parse-author: "npm:^2.0.0" - plist: "npm:^3.0.0" - rcedit: "npm:^3.0.1" - resolve: "npm:^1.1.6" - semver: "npm:^7.1.3" - yargs-parser: "npm:^21.1.1" - bin: - electron-packager: bin/electron-packager.js - checksum: 9e8cac6893d44b797413f2c64c08d452fba94795b2ac5bb24f1cfc238e2eae98f711384fee6b1dd1f8b72d255398968e8efd458d8278afb10335372460c7603e - languageName: node - linkType: hard - "electron-squirrel-startup@npm:1.0.0": version: 1.0.0 resolution: "electron-squirrel-startup@npm:1.0.0" @@ -30660,15 +30599,6 @@ __metadata: languageName: node linkType: hard -"rcedit@npm:^3.0.1": - version: 3.1.0 - resolution: "rcedit@npm:3.1.0" - dependencies: - cross-spawn-windows-exe: "npm:^1.1.0" - checksum: 463b6650a9f6d6ea112a1ed8de898d7e62a78b2190feb35ee03a70320fda131ca523ab7f7efba4fc6f5bbecabe5414b4c745c13ad0f04e203b2c7abec3be1f1f - languageName: node - linkType: hard - "rcedit@npm:^4.0.0": version: 4.0.1 resolution: "rcedit@npm:4.0.1"