app-builder-lib 26.15.2 → 27.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Framework.d.ts +40 -0
- package/dist/Framework.d.ts.map +1 -0
- package/dist/Framework.js +4 -0
- package/dist/Framework.js.map +1 -0
- package/dist/appInfo.d.ts +32 -0
- package/dist/appInfo.d.ts.map +1 -0
- package/dist/appInfo.js +145 -0
- package/dist/appInfo.js.map +1 -0
- package/dist/asar/asar.d.ts +39 -0
- package/dist/asar/asar.d.ts.map +1 -0
- package/dist/asar/asar.js +155 -0
- package/dist/asar/asar.js.map +1 -0
- package/dist/asar/asarFileChecker.d.ts +3 -0
- package/dist/asar/asarFileChecker.d.ts.map +1 -0
- package/dist/asar/asarFileChecker.js +22 -0
- package/dist/asar/asarFileChecker.js.map +1 -0
- package/dist/asar/asarUtil.d.ts +2 -0
- package/dist/asar/asarUtil.d.ts.map +1 -0
- package/dist/asar/asarUtil.js +278 -0
- package/dist/asar/asarUtil.js.map +1 -0
- package/dist/asar/integrity.d.ts +16 -0
- package/dist/asar/integrity.d.ts.map +1 -0
- package/dist/asar/integrity.js +59 -0
- package/dist/asar/integrity.js.map +1 -0
- package/dist/asar/unpackDetector.d.ts +2 -0
- package/dist/asar/unpackDetector.d.ts.map +1 -0
- package/dist/asar/unpackDetector.js +39 -0
- package/dist/asar/unpackDetector.js.map +1 -0
- package/dist/codeSign/certInfo.d.ts +55 -0
- package/dist/codeSign/certInfo.d.ts.map +1 -0
- package/dist/codeSign/certInfo.js +459 -0
- package/dist/codeSign/certInfo.js.map +1 -0
- package/dist/codeSign/codesign.d.ts +4 -0
- package/dist/codeSign/codesign.d.ts.map +1 -0
- package/dist/codeSign/codesign.js +32 -0
- package/dist/codeSign/codesign.js.map +1 -0
- package/dist/codeSign/mac/macCodeSign.d.ts +29 -0
- package/dist/codeSign/mac/macCodeSign.d.ts.map +1 -0
- package/dist/codeSign/mac/macCodeSign.js +273 -0
- package/dist/codeSign/mac/macCodeSign.js.map +1 -0
- package/dist/codeSign/signManager.d.ts +14 -0
- package/dist/codeSign/signManager.d.ts.map +1 -0
- package/dist/codeSign/signManager.js +2 -0
- package/dist/codeSign/signManager.js.map +1 -0
- package/dist/codeSign/win/windowsCodeSign.d.ts +8 -0
- package/dist/codeSign/win/windowsCodeSign.d.ts.map +1 -0
- package/dist/codeSign/win/windowsCodeSign.js +34 -0
- package/dist/codeSign/win/windowsCodeSign.js.map +1 -0
- package/dist/codeSign/win/windowsSignAzureManager.d.ts +18 -0
- package/dist/codeSign/win/windowsSignAzureManager.d.ts.map +1 -0
- package/dist/codeSign/win/windowsSignAzureManager.js +68 -0
- package/dist/codeSign/win/windowsSignAzureManager.js.map +1 -0
- package/dist/codeSign/win/windowsSignToolManager.d.ts +59 -0
- package/dist/codeSign/win/windowsSignToolManager.d.ts.map +1 -0
- package/dist/codeSign/win/windowsSignToolManager.js +364 -0
- package/dist/codeSign/win/windowsSignToolManager.js.map +1 -0
- package/dist/configuration.d.ts +1010 -0
- package/dist/configuration.d.ts.map +1 -0
- package/dist/configuration.js +2 -0
- package/dist/configuration.js.map +1 -0
- package/dist/core.d.ts +61 -0
- package/dist/core.d.ts.map +1 -0
- package/dist/core.js +61 -0
- package/dist/core.js.map +1 -0
- package/dist/electron/ElectronFramework.d.ts +17 -0
- package/dist/electron/ElectronFramework.d.ts.map +1 -0
- package/dist/electron/ElectronFramework.js +236 -0
- package/dist/electron/ElectronFramework.js.map +1 -0
- package/dist/electron/electronVersion.d.ts +7 -0
- package/dist/electron/electronVersion.d.ts.map +1 -0
- package/dist/electron/electronVersion.js +119 -0
- package/dist/electron/electronVersion.js.map +1 -0
- package/dist/electron/injectFFMPEG.d.ts +12 -0
- package/dist/electron/injectFFMPEG.d.ts.map +1 -0
- package/dist/electron/injectFFMPEG.js +53 -0
- package/dist/electron/injectFFMPEG.js.map +1 -0
- package/dist/electron/mac/electronMac.d.ts +2 -0
- package/dist/electron/mac/electronMac.d.ts.map +1 -0
- package/dist/electron/mac/electronMac.js +254 -0
- package/dist/electron/mac/electronMac.js.map +1 -0
- package/dist/electron/search-module.d.ts +24 -0
- package/dist/electron/search-module.d.ts.map +1 -0
- package/dist/electron/search-module.js +68 -0
- package/dist/electron/search-module.js.map +1 -0
- package/dist/electron/win/electronWin.d.ts +2 -0
- package/dist/electron/win/electronWin.d.ts.map +1 -0
- package/dist/electron/win/electronWin.js +36 -0
- package/dist/electron/win/electronWin.js.map +1 -0
- package/dist/errorMessages.d.ts +2 -0
- package/dist/errorMessages.d.ts.map +1 -0
- package/dist/errorMessages.js +8 -0
- package/dist/errorMessages.js.map +1 -0
- package/dist/fileMatcher.d.ts +31 -0
- package/dist/fileMatcher.d.ts.map +1 -0
- package/dist/fileMatcher.js +277 -0
- package/dist/fileMatcher.js.map +1 -0
- package/dist/fileTransformer.d.ts +2 -0
- package/dist/fileTransformer.d.ts.map +1 -0
- package/dist/fileTransformer.js +82 -0
- package/dist/fileTransformer.js.map +1 -0
- package/dist/forge-maker.d.ts +6 -0
- package/dist/forge-maker.d.ts.map +1 -0
- package/dist/forge-maker.js +20 -0
- package/dist/forge-maker.js.map +1 -0
- package/dist/index.d.ts +40 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +77 -0
- package/dist/index.js.map +1 -0
- package/dist/indexInternal.d.ts +46 -0
- package/dist/indexInternal.d.ts.map +1 -0
- package/dist/indexInternal.js +39 -0
- package/dist/indexInternal.js.map +1 -0
- package/dist/linuxPackager.d.ts +13 -0
- package/dist/linuxPackager.d.ts.map +1 -0
- package/dist/linuxPackager.js +75 -0
- package/dist/linuxPackager.js.map +1 -0
- package/dist/macPackager.d.ts +50 -0
- package/dist/macPackager.d.ts.map +1 -0
- package/dist/macPackager.js +442 -0
- package/dist/macPackager.js.map +1 -0
- package/dist/node-module-collector/bunNodeModulesCollector.d.ts +11 -0
- package/dist/node-module-collector/bunNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/bunNodeModulesCollector.js +14 -0
- package/dist/node-module-collector/bunNodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/hoist.d.ts +124 -0
- package/dist/node-module-collector/hoist.d.ts.map +1 -0
- package/dist/node-module-collector/hoist.js +880 -0
- package/dist/node-module-collector/hoist.js.map +1 -0
- package/dist/node-module-collector/index.d.ts +21 -0
- package/dist/node-module-collector/index.d.ts.map +1 -0
- package/dist/node-module-collector/index.js +124 -0
- package/dist/node-module-collector/index.js.map +1 -0
- package/dist/node-module-collector/moduleManager.d.ts +94 -0
- package/dist/node-module-collector/moduleManager.d.ts.map +1 -0
- package/dist/node-module-collector/moduleManager.js +314 -0
- package/dist/node-module-collector/moduleManager.js.map +1 -0
- package/dist/node-module-collector/nodeModulesCollector.d.ts +138 -0
- package/dist/node-module-collector/nodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/nodeModulesCollector.js +421 -0
- package/dist/node-module-collector/nodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/npmNodeModulesCollector.d.ts +15 -0
- package/dist/node-module-collector/npmNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/npmNodeModulesCollector.js +75 -0
- package/dist/node-module-collector/npmNodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/packageManager.d.ts +18 -0
- package/dist/node-module-collector/packageManager.d.ts.map +1 -0
- package/dist/node-module-collector/packageManager.js +137 -0
- package/dist/node-module-collector/packageManager.js.map +1 -0
- package/dist/node-module-collector/pnpmNodeModulesCollector.d.ts +45 -0
- package/dist/node-module-collector/pnpmNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/pnpmNodeModulesCollector.js +184 -0
- package/dist/node-module-collector/pnpmNodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/traversalNodeModulesCollector.d.ts +19 -0
- package/dist/node-module-collector/traversalNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/traversalNodeModulesCollector.js +118 -0
- package/dist/node-module-collector/traversalNodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/types.d.ts +53 -0
- package/dist/node-module-collector/types.d.ts.map +1 -0
- package/dist/node-module-collector/types.js +2 -0
- package/dist/node-module-collector/yarnBerryNodeModulesCollector.d.ts +16 -0
- package/dist/node-module-collector/yarnBerryNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/yarnBerryNodeModulesCollector.js +87 -0
- package/dist/node-module-collector/yarnBerryNodeModulesCollector.js.map +1 -0
- package/dist/node-module-collector/yarnNodeModulesCollector.d.ts +11 -0
- package/dist/node-module-collector/yarnNodeModulesCollector.d.ts.map +1 -0
- package/dist/node-module-collector/yarnNodeModulesCollector.js +18 -0
- package/dist/node-module-collector/yarnNodeModulesCollector.js.map +1 -0
- package/dist/options/AppXOptions.d.ts +106 -0
- package/dist/options/AppXOptions.d.ts.map +1 -0
- package/dist/options/AppXOptions.js +2 -0
- package/dist/options/AppXOptions.js.map +1 -0
- package/dist/options/CommonWindowsInstallerConfiguration.d.ts +48 -0
- package/dist/options/CommonWindowsInstallerConfiguration.d.ts.map +1 -0
- package/dist/options/CommonWindowsInstallerConfiguration.js +47 -0
- package/dist/options/CommonWindowsInstallerConfiguration.js.map +1 -0
- package/dist/options/FileAssociation.d.ts +46 -0
- package/dist/options/FileAssociation.d.ts.map +1 -0
- package/dist/options/FileAssociation.js +2 -0
- package/dist/options/MsiOptions.d.ts +27 -0
- package/dist/options/MsiOptions.d.ts.map +1 -0
- package/dist/options/MsiOptions.js +2 -0
- package/dist/options/MsiOptions.js.map +1 -0
- package/dist/options/MsiWrappedOptions.d.ts +27 -0
- package/dist/options/MsiWrappedOptions.d.ts.map +1 -0
- package/dist/options/MsiWrappedOptions.js +2 -0
- package/dist/options/MsiWrappedOptions.js.map +1 -0
- package/dist/options/PlatformSpecificBuildOptions.d.ts +261 -0
- package/dist/options/PlatformSpecificBuildOptions.d.ts.map +1 -0
- package/dist/options/PlatformSpecificBuildOptions.js +2 -0
- package/dist/options/PlatformSpecificBuildOptions.js.map +1 -0
- package/dist/options/SnapOptions.d.ts +480 -0
- package/dist/options/SnapOptions.d.ts.map +1 -0
- package/dist/options/SnapOptions.js +2 -0
- package/dist/options/SnapOptions.js.map +1 -0
- package/dist/options/SquirrelWindowsOptions.d.ts +47 -0
- package/dist/options/SquirrelWindowsOptions.d.ts.map +1 -0
- package/dist/options/SquirrelWindowsOptions.js +2 -0
- package/dist/options/SquirrelWindowsOptions.js.map +1 -0
- package/dist/options/linuxOptions.d.ts +289 -0
- package/dist/options/linuxOptions.d.ts.map +1 -0
- package/dist/options/linuxOptions.js +2 -0
- package/dist/options/linuxOptions.js.map +1 -0
- package/dist/options/macOptions.d.ts +390 -0
- package/dist/options/macOptions.d.ts.map +1 -0
- package/dist/options/macOptions.js +2 -0
- package/dist/options/macOptions.js.map +1 -0
- package/dist/options/metadata.d.ts +54 -0
- package/dist/options/metadata.d.ts.map +1 -0
- package/dist/options/metadata.js +2 -0
- package/dist/options/metadata.js.map +1 -0
- package/dist/options/pkgOptions.d.ts +137 -0
- package/dist/options/pkgOptions.d.ts.map +1 -0
- package/dist/options/pkgOptions.js +2 -0
- package/dist/options/pkgOptions.js.map +1 -0
- package/dist/options/winOptions.d.ts +166 -0
- package/dist/options/winOptions.d.ts.map +1 -0
- package/dist/options/winOptions.js +2 -0
- package/dist/options/winOptions.js.map +1 -0
- package/dist/packager.d.ts +100 -0
- package/dist/packager.d.ts.map +1 -0
- package/dist/packager.js +491 -0
- package/dist/packager.js.map +1 -0
- package/dist/packagerApi.d.ts +32 -0
- package/dist/packagerApi.d.ts.map +1 -0
- package/dist/packagerApi.js +2 -0
- package/dist/packagerApi.js.map +1 -0
- package/dist/platformPackager.d.ts +132 -0
- package/dist/platformPackager.d.ts.map +1 -0
- package/dist/platformPackager.js +761 -0
- package/dist/platformPackager.js.map +1 -0
- package/dist/presets/rectCra.d.ts +2 -0
- package/dist/presets/rectCra.d.ts.map +1 -0
- package/dist/presets/rectCra.js +19 -0
- package/dist/presets/rectCra.js.map +1 -0
- package/dist/publish/PublishManager.d.ts +33 -0
- package/dist/publish/PublishManager.d.ts.map +1 -0
- package/dist/publish/PublishManager.js +470 -0
- package/dist/publish/PublishManager.js.map +1 -0
- package/dist/publish/updateInfoBuilder.d.ts +15 -0
- package/dist/publish/updateInfoBuilder.d.ts.map +1 -0
- package/dist/publish/updateInfoBuilder.js +221 -0
- package/dist/publish/updateInfoBuilder.js.map +1 -0
- package/dist/targets/ArchiveTarget.d.ts +12 -0
- package/dist/targets/ArchiveTarget.d.ts.map +1 -0
- package/dist/targets/ArchiveTarget.js +93 -0
- package/dist/targets/ArchiveTarget.js.map +1 -0
- package/dist/targets/archive.d.ts +27 -0
- package/dist/targets/archive.d.ts.map +1 -0
- package/dist/targets/archive.js +174 -0
- package/dist/targets/archive.js.map +1 -0
- package/dist/targets/blockmap/blockmap.d.ts +17 -0
- package/dist/targets/blockmap/blockmap.d.ts.map +1 -0
- package/dist/targets/blockmap/blockmap.js +150 -0
- package/dist/targets/blockmap/blockmap.js.map +1 -0
- package/dist/targets/differentialUpdateInfoBuilder.d.ts +16 -0
- package/dist/targets/differentialUpdateInfoBuilder.d.ts.map +1 -0
- package/dist/targets/differentialUpdateInfoBuilder.js +73 -0
- package/dist/targets/differentialUpdateInfoBuilder.js.map +1 -0
- package/dist/targets/linux/FlatpakTarget.d.ts +21 -0
- package/dist/targets/linux/FlatpakTarget.d.ts.map +1 -0
- package/dist/targets/linux/FlatpakTarget.js +156 -0
- package/dist/targets/linux/FlatpakTarget.js.map +1 -0
- package/dist/targets/linux/FpmTarget.d.ts +23 -0
- package/dist/targets/linux/FpmTarget.d.ts.map +1 -0
- package/dist/targets/linux/FpmTarget.js +365 -0
- package/dist/targets/linux/FpmTarget.js.map +1 -0
- package/dist/targets/linux/LinuxTargetHelper.d.ts +24 -0
- package/dist/targets/linux/LinuxTargetHelper.d.ts.map +1 -0
- package/dist/targets/linux/LinuxTargetHelper.js +332 -0
- package/dist/targets/linux/LinuxTargetHelper.js.map +1 -0
- package/dist/targets/linux/appimage/AppImageTarget.d.ts +16 -0
- package/dist/targets/linux/appimage/AppImageTarget.d.ts.map +1 -0
- package/dist/targets/linux/appimage/AppImageTarget.js +141 -0
- package/dist/targets/linux/appimage/AppImageTarget.js.map +1 -0
- package/dist/targets/linux/appimage/appImageUtil.d.ts +57 -0
- package/dist/targets/linux/appimage/appImageUtil.d.ts.map +1 -0
- package/dist/targets/linux/appimage/appImageUtil.js +317 -0
- package/dist/targets/linux/appimage/appImageUtil.js.map +1 -0
- package/dist/targets/linux/appimage/appLauncher.d.ts +4 -0
- package/dist/targets/linux/appimage/appLauncher.d.ts.map +1 -0
- package/dist/targets/linux/appimage/appLauncher.js +91 -0
- package/dist/targets/linux/appimage/appLauncher.js.map +1 -0
- package/dist/targets/linux/snap/SnapTarget.d.ts +37 -0
- package/dist/targets/linux/snap/SnapTarget.d.ts.map +1 -0
- package/dist/targets/linux/snap/SnapTarget.js +96 -0
- package/dist/targets/linux/snap/SnapTarget.js.map +1 -0
- package/dist/targets/linux/snap/core24.d.ts +53 -0
- package/dist/targets/linux/snap/core24.d.ts.map +1 -0
- package/dist/targets/linux/snap/core24.js +444 -0
- package/dist/targets/linux/snap/core24.js.map +1 -0
- package/dist/targets/linux/snap/coreCustom.d.ts +29 -0
- package/dist/targets/linux/snap/coreCustom.d.ts.map +1 -0
- package/dist/targets/linux/snap/coreCustom.js +60 -0
- package/dist/targets/linux/snap/coreCustom.js.map +1 -0
- package/dist/targets/linux/snap/coreLegacy.d.ts +46 -0
- package/dist/targets/linux/snap/coreLegacy.d.ts.map +1 -0
- package/dist/targets/linux/snap/coreLegacy.js +402 -0
- package/dist/targets/linux/snap/coreLegacy.js.map +1 -0
- package/dist/targets/linux/snap/snapcraftBuilder.d.ts +40 -0
- package/dist/targets/linux/snap/snapcraftBuilder.d.ts.map +1 -0
- package/dist/targets/linux/snap/snapcraftBuilder.js +414 -0
- package/dist/targets/linux/snap/snapcraftBuilder.js.map +1 -0
- package/dist/targets/mac/MacTargetHelper.d.ts +30 -0
- package/dist/targets/mac/MacTargetHelper.d.ts.map +1 -0
- package/dist/targets/mac/MacTargetHelper.js +267 -0
- package/dist/targets/mac/MacTargetHelper.js.map +1 -0
- package/dist/targets/mac/pkg.d.ts +31 -0
- package/dist/targets/mac/pkg.d.ts.map +1 -0
- package/dist/targets/mac/pkg.js +271 -0
- package/dist/targets/mac/pkg.js.map +1 -0
- package/dist/targets/targetFactory.d.ts +13 -0
- package/dist/targets/targetFactory.d.ts.map +1 -0
- package/dist/targets/targetFactory.js +94 -0
- package/dist/targets/targetFactory.js.map +1 -0
- package/dist/targets/targetUtil.d.ts +16 -0
- package/dist/targets/targetUtil.d.ts.map +1 -0
- package/dist/targets/targetUtil.js +40 -0
- package/dist/targets/targetUtil.js.map +1 -0
- package/dist/targets/win/AppxCapabilities.d.ts +9 -0
- package/dist/targets/win/AppxCapabilities.d.ts.map +1 -0
- package/dist/targets/win/AppxCapabilities.js +254 -0
- package/dist/targets/win/AppxCapabilities.js.map +1 -0
- package/dist/targets/win/AppxTarget.d.ts +18 -0
- package/dist/targets/win/AppxTarget.d.ts.map +1 -0
- package/dist/targets/win/AppxTarget.js +398 -0
- package/dist/targets/win/AppxTarget.js.map +1 -0
- package/dist/targets/win/MsiTarget.d.ts +29 -0
- package/dist/targets/win/MsiTarget.d.ts.map +1 -0
- package/dist/targets/win/MsiTarget.js +268 -0
- package/dist/targets/win/MsiTarget.js.map +1 -0
- package/dist/targets/win/MsiWrappedTarget.d.ts +20 -0
- package/dist/targets/win/MsiWrappedTarget.d.ts.map +1 -0
- package/dist/targets/win/MsiWrappedTarget.js +77 -0
- package/dist/targets/win/MsiWrappedTarget.js.map +1 -0
- package/dist/targets/win/nsis/Commands.d.ts +10 -0
- package/dist/targets/win/nsis/Commands.d.ts.map +1 -0
- package/dist/targets/win/nsis/Commands.js +2 -0
- package/dist/targets/win/nsis/Commands.js.map +1 -0
- package/dist/targets/win/nsis/Defines.d.ts +81 -0
- package/dist/targets/win/nsis/Defines.d.ts.map +1 -0
- package/dist/targets/win/nsis/Defines.js +2 -0
- package/dist/targets/win/nsis/Defines.js.map +1 -0
- package/dist/targets/win/nsis/NsisTarget.d.ts +43 -0
- package/dist/targets/win/nsis/NsisTarget.d.ts.map +1 -0
- package/dist/targets/win/nsis/NsisTarget.js +726 -0
- package/dist/targets/win/nsis/NsisTarget.js.map +1 -0
- package/dist/targets/win/nsis/WebInstallerTarget.d.ts +14 -0
- package/dist/targets/win/nsis/WebInstallerTarget.d.ts.map +1 -0
- package/dist/targets/win/nsis/WebInstallerTarget.js +43 -0
- package/dist/targets/win/nsis/WebInstallerTarget.js.map +1 -0
- package/dist/targets/win/nsis/nsisLang.d.ts +11 -0
- package/dist/targets/win/nsis/nsisLang.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisLang.js +94 -0
- package/dist/targets/win/nsis/nsisLang.js.map +1 -0
- package/dist/targets/win/nsis/nsisLicense.d.ts +5 -0
- package/dist/targets/win/nsis/nsisLicense.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisLicense.js +73 -0
- package/dist/targets/win/nsis/nsisLicense.js.map +1 -0
- package/dist/targets/win/nsis/nsisOptions.d.ts +275 -0
- package/dist/targets/win/nsis/nsisOptions.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisOptions.js +2 -0
- package/dist/targets/win/nsis/nsisOptions.js.map +1 -0
- package/dist/targets/win/nsis/nsisScriptGenerator.d.ts +13 -0
- package/dist/targets/win/nsis/nsisScriptGenerator.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisScriptGenerator.js +59 -0
- package/dist/targets/win/nsis/nsisScriptGenerator.js.map +1 -0
- package/dist/targets/win/nsis/nsisUtil.d.ts +26 -0
- package/dist/targets/win/nsis/nsisUtil.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisUtil.js +218 -0
- package/dist/targets/win/nsis/nsisUtil.js.map +1 -0
- package/dist/targets/win/nsis/nsisValidation.d.ts +19 -0
- package/dist/targets/win/nsis/nsisValidation.d.ts.map +1 -0
- package/dist/targets/win/nsis/nsisValidation.js +49 -0
- package/dist/targets/win/nsis/nsisValidation.js.map +1 -0
- package/dist/toolsets/7zip.d.ts +9 -0
- package/dist/toolsets/7zip.d.ts.map +1 -0
- package/dist/toolsets/7zip.js +80 -0
- package/dist/toolsets/7zip.js.map +1 -0
- package/dist/toolsets/appimage.d.ts +20 -0
- package/dist/toolsets/appimage.d.ts.map +1 -0
- package/dist/toolsets/appimage.js +67 -0
- package/dist/toolsets/appimage.js.map +1 -0
- package/dist/toolsets/custom.d.ts +5 -0
- package/dist/toolsets/custom.d.ts.map +1 -0
- package/dist/toolsets/custom.js +200 -0
- package/dist/toolsets/custom.js.map +1 -0
- package/dist/toolsets/fpm.d.ts +3 -0
- package/dist/toolsets/fpm.d.ts.map +1 -0
- package/dist/toolsets/fpm.js +49 -0
- package/dist/toolsets/fpm.js.map +1 -0
- package/dist/toolsets/icons.d.ts +12 -0
- package/dist/toolsets/icons.d.ts.map +1 -0
- package/dist/toolsets/icons.js +36 -0
- package/dist/toolsets/icons.js.map +1 -0
- package/dist/toolsets/linuxToolsMac.d.ts +8 -0
- package/dist/toolsets/linuxToolsMac.d.ts.map +1 -0
- package/dist/toolsets/linuxToolsMac.js +31 -0
- package/dist/toolsets/linuxToolsMac.js.map +1 -0
- package/dist/toolsets/nsis.d.ts +13 -0
- package/dist/toolsets/nsis.d.ts.map +1 -0
- package/dist/toolsets/nsis.js +100 -0
- package/dist/toolsets/nsis.js.map +1 -0
- package/dist/toolsets/winCodeSign.d.ts +42 -0
- package/dist/toolsets/winCodeSign.d.ts.map +1 -0
- package/dist/toolsets/winCodeSign.js +142 -0
- package/dist/toolsets/winCodeSign.js.map +1 -0
- package/dist/toolsets/wine.d.ts +6 -0
- package/dist/toolsets/wine.d.ts.map +1 -0
- package/dist/toolsets/wine.js +79 -0
- package/dist/toolsets/wine.js.map +1 -0
- package/dist/util/AppFileWalker.d.ts +14 -0
- package/dist/util/AppFileWalker.d.ts.map +1 -0
- package/dist/util/AppFileWalker.js +69 -0
- package/dist/util/AppFileWalker.js.map +1 -0
- package/dist/util/NodeModuleCopyHelper.d.ts +2 -0
- package/dist/util/NodeModuleCopyHelper.d.ts.map +1 -0
- package/dist/util/NodeModuleCopyHelper.js +160 -0
- package/dist/util/NodeModuleCopyHelper.js.map +1 -0
- package/dist/util/appFileCopier.d.ts +17 -0
- package/dist/util/appFileCopier.d.ts.map +1 -0
- package/dist/util/appFileCopier.js +190 -0
- package/dist/util/appFileCopier.js.map +1 -0
- package/dist/util/asyncEventEmitter.d.ts +34 -0
- package/dist/util/asyncEventEmitter.d.ts.map +1 -0
- package/dist/util/asyncEventEmitter.js +56 -0
- package/dist/util/asyncEventEmitter.js.map +1 -0
- package/dist/util/bundledTool.d.ts +8 -0
- package/dist/util/bundledTool.d.ts.map +1 -0
- package/dist/util/bundledTool.js +16 -0
- package/dist/util/bundledTool.js.map +1 -0
- package/dist/util/cacheManager.d.ts +19 -0
- package/dist/util/cacheManager.d.ts.map +1 -0
- package/dist/util/cacheManager.js +65 -0
- package/dist/util/cacheManager.js.map +1 -0
- package/dist/util/cacheState.d.ts +29 -0
- package/dist/util/cacheState.d.ts.map +1 -0
- package/dist/util/cacheState.js +134 -0
- package/dist/util/cacheState.js.map +1 -0
- package/dist/util/config/config.d.ts +13 -0
- package/dist/util/config/config.d.ts.map +1 -0
- package/dist/util/config/config.js +236 -0
- package/dist/util/config/config.js.map +1 -0
- package/dist/util/config/load.d.ts +20 -0
- package/dist/util/config/load.d.ts.map +1 -0
- package/dist/util/config/load.js +122 -0
- package/dist/util/config/load.js.map +1 -0
- package/dist/util/config/schemaValidator.d.ts +8 -0
- package/dist/util/config/schemaValidator.d.ts.map +1 -0
- package/dist/util/config/schemaValidator.js +161 -0
- package/dist/util/config/schemaValidator.js.map +1 -0
- package/dist/util/dynamicImport.d.ts +2 -0
- package/dist/util/dynamicImport.d.ts.map +1 -0
- package/dist/util/dynamicImport.js +9 -0
- package/dist/util/dynamicImport.js.map +1 -0
- package/dist/util/electronGet.d.ts +68 -0
- package/dist/util/electronGet.d.ts.map +1 -0
- package/dist/util/electronGet.js +560 -0
- package/dist/util/electronGet.js.map +1 -0
- package/dist/util/filter.d.ts +2 -0
- package/dist/util/filter.d.ts.map +1 -0
- package/dist/util/filter.js +64 -0
- package/dist/util/filter.js.map +1 -0
- package/dist/util/flags.d.ts +16 -0
- package/dist/util/flags.d.ts.map +1 -0
- package/dist/util/flags.js +53 -0
- package/dist/util/flags.js.map +1 -0
- package/dist/util/hash.d.ts +2 -0
- package/dist/util/hash.d.ts.map +1 -0
- package/dist/util/hash.js +16 -0
- package/dist/util/hash.js.map +1 -0
- package/dist/util/iconConverter.d.ts +29 -0
- package/dist/util/iconConverter.d.ts.map +1 -0
- package/dist/util/iconConverter.js +255 -0
- package/dist/util/iconConverter.js.map +1 -0
- package/dist/util/langs.d.ts +190 -0
- package/dist/util/langs.d.ts.map +1 -0
- package/dist/util/langs.js +432 -0
- package/dist/util/langs.js.map +1 -0
- package/dist/util/license.d.ts +17 -0
- package/dist/util/license.d.ts.map +1 -0
- package/dist/util/license.js +42 -0
- package/dist/util/license.js.map +1 -0
- package/dist/util/mac/macosIconComposer.d.ts +11 -0
- package/dist/util/mac/macosIconComposer.d.ts.map +1 -0
- package/dist/util/mac/macosIconComposer.js +99 -0
- package/dist/util/mac/macosIconComposer.js.map +1 -0
- package/dist/util/mac/macosVersion.d.ts +4 -0
- package/dist/util/mac/macosVersion.d.ts.map +1 -0
- package/dist/util/mac/macosVersion.js +31 -0
- package/dist/util/mac/macosVersion.js.map +1 -0
- package/dist/util/mac/plist.d.ts +8 -0
- package/dist/util/mac/plist.d.ts.map +1 -0
- package/dist/util/mac/plist.js +27 -0
- package/dist/util/mac/plist.js.map +1 -0
- package/dist/util/macroExpander.d.ts +4 -0
- package/dist/util/macroExpander.d.ts.map +1 -0
- package/dist/util/macroExpander.js +61 -0
- package/dist/util/macroExpander.js.map +1 -0
- package/dist/util/normalizePackageData.d.ts +2 -0
- package/dist/util/normalizePackageData.d.ts.map +1 -0
- package/dist/util/normalizePackageData.js +323 -0
- package/dist/util/normalizePackageData.js.map +1 -0
- package/dist/util/packageMetadata.d.ts +2 -0
- package/dist/util/packageMetadata.d.ts.map +1 -0
- package/dist/util/packageMetadata.js +118 -0
- package/dist/util/packageMetadata.js.map +1 -0
- package/dist/util/pathManager.d.ts +4 -0
- package/dist/util/pathManager.d.ts.map +1 -0
- package/dist/util/pathManager.js +17 -0
- package/dist/util/pathManager.js.map +1 -0
- package/dist/util/rebuild.d.ts +3 -0
- package/dist/util/rebuild.d.ts.map +1 -0
- package/dist/util/rebuild.js +54 -0
- package/dist/util/rebuild.js.map +1 -0
- package/dist/util/repositoryInfo.d.ts +4 -0
- package/dist/util/repositoryInfo.d.ts.map +1 -0
- package/dist/util/repositoryInfo.js +76 -0
- package/dist/util/repositoryInfo.js.map +1 -0
- package/dist/util/resolve.d.ts +3 -0
- package/dist/util/resolve.d.ts.map +1 -0
- package/dist/util/resolve.js +56 -0
- package/dist/util/resolve.js.map +1 -0
- package/dist/util/timer.d.ts +12 -0
- package/dist/util/timer.d.ts.map +1 -0
- package/dist/util/timer.js +23 -0
- package/dist/util/timer.js.map +1 -0
- package/dist/util/toolsetLock.d.ts +2 -0
- package/dist/util/toolsetLock.d.ts.map +1 -0
- package/dist/util/toolsetLock.js +20 -0
- package/dist/util/toolsetLock.js.map +1 -0
- package/dist/util/win/resEdit.d.ts +11 -0
- package/dist/util/win/resEdit.d.ts.map +1 -0
- package/dist/util/win/resEdit.js +46 -0
- package/dist/util/win/resEdit.js.map +1 -0
- package/dist/util/yarn.d.ts +23 -0
- package/dist/util/yarn.d.ts.map +1 -0
- package/dist/util/yarn.js +153 -0
- package/dist/util/yarn.js.map +1 -0
- package/dist/version.d.ts +2 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/version.js +2 -0
- package/dist/version.js.map +1 -0
- package/dist/vm/MonoVm.d.ts +9 -0
- package/dist/vm/MonoVm.d.ts.map +1 -0
- package/dist/vm/MonoVm.js +16 -0
- package/dist/vm/MonoVm.js.map +1 -0
- package/dist/vm/ParallelsVm.d.ts +24 -0
- package/dist/vm/ParallelsVm.d.ts.map +1 -0
- package/dist/vm/ParallelsVm.js +107 -0
- package/dist/vm/ParallelsVm.js.map +1 -0
- package/dist/vm/PwshVm.d.ts +7 -0
- package/dist/vm/PwshVm.d.ts.map +1 -0
- package/dist/vm/PwshVm.js +21 -0
- package/dist/vm/PwshVm.js.map +1 -0
- package/dist/vm/WineVm.d.ts +14 -0
- package/dist/vm/WineVm.d.ts.map +1 -0
- package/dist/vm/WineVm.js +35 -0
- package/dist/vm/WineVm.js.map +1 -0
- package/dist/vm/vm.d.ts +15 -0
- package/dist/vm/vm.d.ts.map +1 -0
- package/dist/vm/vm.js +81 -0
- package/dist/vm/vm.js.map +1 -0
- package/dist/winPackager.d.ts +30 -0
- package/dist/winPackager.d.ts.map +1 -0
- package/dist/winPackager.js +270 -0
- package/dist/winPackager.js.map +1 -0
- package/helpers/package.json +6 -0
- package/helpers/remote-rebuild.js +2 -4
- package/package.json +30 -33
- package/scheme.json +379 -721
- package/out/Framework.d.ts +0 -36
- package/out/Framework.js +0 -7
- package/out/Framework.js.map +0 -1
- package/out/ProtonFramework.d.ts +0 -10
- package/out/ProtonFramework.js +0 -94
- package/out/ProtonFramework.js.map +0 -1
- package/out/appInfo.d.ts +0 -31
- package/out/appInfo.js +0 -152
- package/out/appInfo.js.map +0 -1
- package/out/asar/asar.d.ts +0 -38
- package/out/asar/asar.js +0 -163
- package/out/asar/asar.js.map +0 -1
- package/out/asar/asarFileChecker.d.ts +0 -2
- package/out/asar/asarFileChecker.js +0 -25
- package/out/asar/asarFileChecker.js.map +0 -1
- package/out/asar/asarUtil.d.ts +0 -1
- package/out/asar/asarUtil.js +0 -285
- package/out/asar/asarUtil.js.map +0 -1
- package/out/asar/integrity.d.ts +0 -15
- package/out/asar/integrity.js +0 -62
- package/out/asar/integrity.js.map +0 -1
- package/out/asar/unpackDetector.d.ts +0 -1
- package/out/asar/unpackDetector.js +0 -43
- package/out/asar/unpackDetector.js.map +0 -1
- package/out/binDownload.d.ts +0 -5
- package/out/binDownload.js +0 -104
- package/out/binDownload.js.map +0 -1
- package/out/codeSign/certInfo.d.ts +0 -54
- package/out/codeSign/certInfo.js +0 -466
- package/out/codeSign/certInfo.js.map +0 -1
- package/out/codeSign/codesign.d.ts +0 -3
- package/out/codeSign/codesign.js +0 -33
- package/out/codeSign/codesign.js.map +0 -1
- package/out/codeSign/macCodeSign.d.ts +0 -28
- package/out/codeSign/macCodeSign.js +0 -284
- package/out/codeSign/macCodeSign.js.map +0 -1
- package/out/codeSign/signManager.d.ts +0 -13
- package/out/codeSign/signManager.js +0 -3
- package/out/codeSign/signManager.js.map +0 -1
- package/out/codeSign/windowsCodeSign.d.ts +0 -7
- package/out/codeSign/windowsCodeSign.js +0 -38
- package/out/codeSign/windowsCodeSign.js.map +0 -1
- package/out/codeSign/windowsSignAzureManager.d.ts +0 -17
- package/out/codeSign/windowsSignAzureManager.js +0 -73
- package/out/codeSign/windowsSignAzureManager.js.map +0 -1
- package/out/codeSign/windowsSignToolManager.d.ts +0 -58
- package/out/codeSign/windowsSignToolManager.js +0 -376
- package/out/codeSign/windowsSignToolManager.js.map +0 -1
- package/out/configuration.d.ts +0 -532
- package/out/configuration.js +0 -3
- package/out/configuration.js.map +0 -1
- package/out/core.d.ts +0 -60
- package/out/core.js +0 -66
- package/out/core.js.map +0 -1
- package/out/electron/ElectronFramework.d.ts +0 -16
- package/out/electron/ElectronFramework.js +0 -242
- package/out/electron/ElectronFramework.js.map +0 -1
- package/out/electron/electronMac.d.ts +0 -1
- package/out/electron/electronMac.js +0 -262
- package/out/electron/electronMac.js.map +0 -1
- package/out/electron/electronVersion.d.ts +0 -6
- package/out/electron/electronVersion.js +0 -125
- package/out/electron/electronVersion.js.map +0 -1
- package/out/electron/electronWin.d.ts +0 -1
- package/out/electron/electronWin.js +0 -38
- package/out/electron/electronWin.js.map +0 -1
- package/out/electron/injectFFMPEG.d.ts +0 -11
- package/out/electron/injectFFMPEG.js +0 -57
- package/out/electron/injectFFMPEG.js.map +0 -1
- package/out/electron/search-module.d.ts +0 -23
- package/out/electron/search-module.js +0 -73
- package/out/electron/search-module.js.map +0 -1
- package/out/errorMessages.d.ts +0 -1
- package/out/errorMessages.js +0 -11
- package/out/errorMessages.js.map +0 -1
- package/out/fileMatcher.d.ts +0 -29
- package/out/fileMatcher.js +0 -292
- package/out/fileMatcher.js.map +0 -1
- package/out/fileTransformer.d.ts +0 -1
- package/out/fileTransformer.js +0 -107
- package/out/fileTransformer.js.map +0 -1
- package/out/forge-maker.d.ts +0 -5
- package/out/forge-maker.js +0 -23
- package/out/forge-maker.js.map +0 -1
- package/out/frameworks/LibUiFramework.d.ts +0 -47
- package/out/frameworks/LibUiFramework.js +0 -197
- package/out/frameworks/LibUiFramework.js.map +0 -1
- package/out/index.d.ts +0 -39
- package/out/index.js +0 -99
- package/out/index.js.map +0 -1
- package/out/linuxPackager.d.ts +0 -12
- package/out/linuxPackager.js +0 -77
- package/out/linuxPackager.js.map +0 -1
- package/out/mac/MacTargetHelper.d.ts +0 -29
- package/out/mac/MacTargetHelper.js +0 -273
- package/out/mac/MacTargetHelper.js.map +0 -1
- package/out/macPackager.d.ts +0 -49
- package/out/macPackager.js +0 -445
- package/out/macPackager.js.map +0 -1
- package/out/node-module-collector/bunNodeModulesCollector.d.ts +0 -10
- package/out/node-module-collector/bunNodeModulesCollector.js +0 -18
- package/out/node-module-collector/bunNodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/hoist.d.ts +0 -123
- package/out/node-module-collector/hoist.js +0 -884
- package/out/node-module-collector/hoist.js.map +0 -1
- package/out/node-module-collector/index.d.ts +0 -18
- package/out/node-module-collector/index.js +0 -130
- package/out/node-module-collector/index.js.map +0 -1
- package/out/node-module-collector/moduleManager.d.ts +0 -93
- package/out/node-module-collector/moduleManager.js +0 -321
- package/out/node-module-collector/moduleManager.js.map +0 -1
- package/out/node-module-collector/nodeModulesCollector.d.ts +0 -137
- package/out/node-module-collector/nodeModulesCollector.js +0 -428
- package/out/node-module-collector/nodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/npmNodeModulesCollector.d.ts +0 -14
- package/out/node-module-collector/npmNodeModulesCollector.js +0 -80
- package/out/node-module-collector/npmNodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/packageManager.d.ts +0 -17
- package/out/node-module-collector/packageManager.js +0 -144
- package/out/node-module-collector/packageManager.js.map +0 -1
- package/out/node-module-collector/pnpmNodeModulesCollector.d.ts +0 -44
- package/out/node-module-collector/pnpmNodeModulesCollector.js +0 -191
- package/out/node-module-collector/pnpmNodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/traversalNodeModulesCollector.d.ts +0 -18
- package/out/node-module-collector/traversalNodeModulesCollector.js +0 -122
- package/out/node-module-collector/traversalNodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/types.d.ts +0 -52
- package/out/node-module-collector/types.js +0 -3
- package/out/node-module-collector/yarnBerryNodeModulesCollector.d.ts +0 -15
- package/out/node-module-collector/yarnBerryNodeModulesCollector.js +0 -93
- package/out/node-module-collector/yarnBerryNodeModulesCollector.js.map +0 -1
- package/out/node-module-collector/yarnNodeModulesCollector.d.ts +0 -10
- package/out/node-module-collector/yarnNodeModulesCollector.js +0 -22
- package/out/node-module-collector/yarnNodeModulesCollector.js.map +0 -1
- package/out/options/AppXOptions.d.ts +0 -105
- package/out/options/AppXOptions.js +0 -3
- package/out/options/AppXOptions.js.map +0 -1
- package/out/options/CommonWindowsInstallerConfiguration.d.ts +0 -47
- package/out/options/CommonWindowsInstallerConfiguration.js +0 -51
- package/out/options/CommonWindowsInstallerConfiguration.js.map +0 -1
- package/out/options/FileAssociation.d.ts +0 -45
- package/out/options/FileAssociation.js +0 -3
- package/out/options/MsiOptions.d.ts +0 -26
- package/out/options/MsiOptions.js +0 -3
- package/out/options/MsiOptions.js.map +0 -1
- package/out/options/MsiWrappedOptions.d.ts +0 -26
- package/out/options/MsiWrappedOptions.js +0 -3
- package/out/options/MsiWrappedOptions.js.map +0 -1
- package/out/options/PlatformSpecificBuildOptions.d.ts +0 -238
- package/out/options/PlatformSpecificBuildOptions.js +0 -3
- package/out/options/PlatformSpecificBuildOptions.js.map +0 -1
- package/out/options/SnapOptions.d.ts +0 -500
- package/out/options/SnapOptions.js +0 -3
- package/out/options/SnapOptions.js.map +0 -1
- package/out/options/SquirrelWindowsOptions.d.ts +0 -46
- package/out/options/SquirrelWindowsOptions.js +0 -3
- package/out/options/SquirrelWindowsOptions.js.map +0 -1
- package/out/options/linuxOptions.d.ts +0 -287
- package/out/options/linuxOptions.js +0 -3
- package/out/options/linuxOptions.js.map +0 -1
- package/out/options/macOptions.d.ts +0 -388
- package/out/options/macOptions.js +0 -3
- package/out/options/macOptions.js.map +0 -1
- package/out/options/metadata.d.ts +0 -53
- package/out/options/metadata.js +0 -3
- package/out/options/metadata.js.map +0 -1
- package/out/options/pkgOptions.d.ts +0 -136
- package/out/options/pkgOptions.js +0 -3
- package/out/options/pkgOptions.js.map +0 -1
- package/out/options/winOptions.d.ts +0 -164
- package/out/options/winOptions.js +0 -3
- package/out/options/winOptions.js.map +0 -1
- package/out/packager.d.ts +0 -99
- package/out/packager.js +0 -515
- package/out/packager.js.map +0 -1
- package/out/packagerApi.d.ts +0 -31
- package/out/packagerApi.js +0 -3
- package/out/packagerApi.js.map +0 -1
- package/out/platformPackager.d.ts +0 -101
- package/out/platformPackager.js +0 -714
- package/out/platformPackager.js.map +0 -1
- package/out/presets/rectCra.d.ts +0 -1
- package/out/presets/rectCra.js +0 -22
- package/out/presets/rectCra.js.map +0 -1
- package/out/publish/PublishManager.d.ts +0 -30
- package/out/publish/PublishManager.js +0 -497
- package/out/publish/PublishManager.js.map +0 -1
- package/out/publish/updateInfoBuilder.d.ts +0 -14
- package/out/publish/updateInfoBuilder.js +0 -226
- package/out/publish/updateInfoBuilder.js.map +0 -1
- package/out/targets/AppxCapabilities.d.ts +0 -8
- package/out/targets/AppxCapabilities.js +0 -258
- package/out/targets/AppxCapabilities.js.map +0 -1
- package/out/targets/AppxTarget.d.ts +0 -17
- package/out/targets/AppxTarget.js +0 -403
- package/out/targets/AppxTarget.js.map +0 -1
- package/out/targets/ArchiveTarget.d.ts +0 -11
- package/out/targets/ArchiveTarget.js +0 -88
- package/out/targets/ArchiveTarget.js.map +0 -1
- package/out/targets/FlatpakTarget.d.ts +0 -20
- package/out/targets/FlatpakTarget.js +0 -159
- package/out/targets/FlatpakTarget.js.map +0 -1
- package/out/targets/FpmTarget.d.ts +0 -22
- package/out/targets/FpmTarget.js +0 -372
- package/out/targets/FpmTarget.js.map +0 -1
- package/out/targets/LinuxTargetHelper.d.ts +0 -23
- package/out/targets/LinuxTargetHelper.js +0 -346
- package/out/targets/LinuxTargetHelper.js.map +0 -1
- package/out/targets/MsiTarget.d.ts +0 -28
- package/out/targets/MsiTarget.js +0 -268
- package/out/targets/MsiTarget.js.map +0 -1
- package/out/targets/MsiWrappedTarget.d.ts +0 -19
- package/out/targets/MsiWrappedTarget.js +0 -80
- package/out/targets/MsiWrappedTarget.js.map +0 -1
- package/out/targets/appimage/AppImageTarget.d.ts +0 -15
- package/out/targets/appimage/AppImageTarget.js +0 -147
- package/out/targets/appimage/AppImageTarget.js.map +0 -1
- package/out/targets/appimage/appImageUtil.d.ts +0 -56
- package/out/targets/appimage/appImageUtil.js +0 -323
- package/out/targets/appimage/appImageUtil.js.map +0 -1
- package/out/targets/appimage/appLauncher.d.ts +0 -3
- package/out/targets/appimage/appLauncher.js +0 -95
- package/out/targets/appimage/appLauncher.js.map +0 -1
- package/out/targets/archive.d.ts +0 -26
- package/out/targets/archive.js +0 -178
- package/out/targets/archive.js.map +0 -1
- package/out/targets/blockmap/blockmap.d.ts +0 -16
- package/out/targets/blockmap/blockmap.js +0 -153
- package/out/targets/blockmap/blockmap.js.map +0 -1
- package/out/targets/differentialUpdateInfoBuilder.d.ts +0 -15
- package/out/targets/differentialUpdateInfoBuilder.js +0 -80
- package/out/targets/differentialUpdateInfoBuilder.js.map +0 -1
- package/out/targets/nsis/Commands.d.ts +0 -9
- package/out/targets/nsis/Commands.js +0 -3
- package/out/targets/nsis/Commands.js.map +0 -1
- package/out/targets/nsis/Defines.d.ts +0 -80
- package/out/targets/nsis/Defines.js +0 -3
- package/out/targets/nsis/Defines.js.map +0 -1
- package/out/targets/nsis/NsisTarget.d.ts +0 -37
- package/out/targets/nsis/NsisTarget.js +0 -729
- package/out/targets/nsis/NsisTarget.js.map +0 -1
- package/out/targets/nsis/WebInstallerTarget.d.ts +0 -13
- package/out/targets/nsis/WebInstallerTarget.js +0 -47
- package/out/targets/nsis/WebInstallerTarget.js.map +0 -1
- package/out/targets/nsis/nsisLang.d.ts +0 -10
- package/out/targets/nsis/nsisLang.js +0 -100
- package/out/targets/nsis/nsisLang.js.map +0 -1
- package/out/targets/nsis/nsisLicense.d.ts +0 -4
- package/out/targets/nsis/nsisLicense.js +0 -77
- package/out/targets/nsis/nsisLicense.js.map +0 -1
- package/out/targets/nsis/nsisOptions.d.ts +0 -274
- package/out/targets/nsis/nsisOptions.js +0 -3
- package/out/targets/nsis/nsisOptions.js.map +0 -1
- package/out/targets/nsis/nsisScriptGenerator.d.ts +0 -12
- package/out/targets/nsis/nsisScriptGenerator.js +0 -64
- package/out/targets/nsis/nsisScriptGenerator.js.map +0 -1
- package/out/targets/nsis/nsisUtil.d.ts +0 -25
- package/out/targets/nsis/nsisUtil.js +0 -225
- package/out/targets/nsis/nsisUtil.js.map +0 -1
- package/out/targets/nsis/nsisValidation.d.ts +0 -18
- package/out/targets/nsis/nsisValidation.js +0 -53
- package/out/targets/nsis/nsisValidation.js.map +0 -1
- package/out/targets/pkg.d.ts +0 -30
- package/out/targets/pkg.js +0 -279
- package/out/targets/pkg.js.map +0 -1
- package/out/targets/snap/SnapTarget.d.ts +0 -36
- package/out/targets/snap/SnapTarget.js +0 -105
- package/out/targets/snap/SnapTarget.js.map +0 -1
- package/out/targets/snap/core24.d.ts +0 -52
- package/out/targets/snap/core24.js +0 -449
- package/out/targets/snap/core24.js.map +0 -1
- package/out/targets/snap/coreCustom.d.ts +0 -28
- package/out/targets/snap/coreCustom.js +0 -63
- package/out/targets/snap/coreCustom.js.map +0 -1
- package/out/targets/snap/coreLegacy.d.ts +0 -43
- package/out/targets/snap/coreLegacy.js +0 -416
- package/out/targets/snap/coreLegacy.js.map +0 -1
- package/out/targets/snap/snapcraftBuilder.d.ts +0 -39
- package/out/targets/snap/snapcraftBuilder.js +0 -419
- package/out/targets/snap/snapcraftBuilder.js.map +0 -1
- package/out/targets/targetFactory.d.ts +0 -12
- package/out/targets/targetFactory.js +0 -101
- package/out/targets/targetFactory.js.map +0 -1
- package/out/targets/targetUtil.d.ts +0 -14
- package/out/targets/targetUtil.js +0 -47
- package/out/targets/targetUtil.js.map +0 -1
- package/out/toolsets/7zip.d.ts +0 -2
- package/out/toolsets/7zip.js +0 -72
- package/out/toolsets/7zip.js.map +0 -1
- package/out/toolsets/icons.d.ts +0 -8
- package/out/toolsets/icons.js +0 -37
- package/out/toolsets/icons.js.map +0 -1
- package/out/toolsets/linux.d.ts +0 -26
- package/out/toolsets/linux.js +0 -146
- package/out/toolsets/linux.js.map +0 -1
- package/out/toolsets/windows.d.ts +0 -61
- package/out/toolsets/windows.js +0 -259
- package/out/toolsets/windows.js.map +0 -1
- package/out/toolsets/wine.d.ts +0 -5
- package/out/toolsets/wine.js +0 -100
- package/out/toolsets/wine.js.map +0 -1
- package/out/util/AppFileWalker.d.ts +0 -13
- package/out/util/AppFileWalker.js +0 -74
- package/out/util/AppFileWalker.js.map +0 -1
- package/out/util/NodeModuleCopyHelper.d.ts +0 -1
- package/out/util/NodeModuleCopyHelper.js +0 -165
- package/out/util/NodeModuleCopyHelper.js.map +0 -1
- package/out/util/appFileCopier.d.ts +0 -16
- package/out/util/appFileCopier.js +0 -251
- package/out/util/appFileCopier.js.map +0 -1
- package/out/util/asyncEventEmitter.d.ts +0 -33
- package/out/util/asyncEventEmitter.js +0 -63
- package/out/util/asyncEventEmitter.js.map +0 -1
- package/out/util/bundledTool.d.ts +0 -7
- package/out/util/bundledTool.js +0 -20
- package/out/util/bundledTool.js.map +0 -1
- package/out/util/cacheManager.d.ts +0 -18
- package/out/util/cacheManager.js +0 -70
- package/out/util/cacheManager.js.map +0 -1
- package/out/util/cacheState.d.ts +0 -28
- package/out/util/cacheState.js +0 -143
- package/out/util/cacheState.js.map +0 -1
- package/out/util/config/config.d.ts +0 -12
- package/out/util/config/config.js +0 -256
- package/out/util/config/config.js.map +0 -1
- package/out/util/config/load.d.ts +0 -19
- package/out/util/config/load.js +0 -129
- package/out/util/config/load.js.map +0 -1
- package/out/util/config/schemaValidator.d.ts +0 -7
- package/out/util/config/schemaValidator.js +0 -154
- package/out/util/config/schemaValidator.js.map +0 -1
- package/out/util/dynamicImport.d.ts +0 -1
- package/out/util/dynamicImport.js +0 -12
- package/out/util/dynamicImport.js.map +0 -1
- package/out/util/electronGet.d.ts +0 -61
- package/out/util/electronGet.js +0 -464
- package/out/util/electronGet.js.map +0 -1
- package/out/util/envPath.d.ts +0 -2
- package/out/util/envPath.js +0 -28
- package/out/util/envPath.js.map +0 -1
- package/out/util/filter.d.ts +0 -1
- package/out/util/filter.js +0 -68
- package/out/util/filter.js.map +0 -1
- package/out/util/flags.d.ts +0 -3
- package/out/util/flags.js +0 -16
- package/out/util/flags.js.map +0 -1
- package/out/util/hash.d.ts +0 -1
- package/out/util/hash.js +0 -19
- package/out/util/hash.js.map +0 -1
- package/out/util/iconConverter.d.ts +0 -25
- package/out/util/iconConverter.js +0 -260
- package/out/util/iconConverter.js.map +0 -1
- package/out/util/langs.d.ts +0 -189
- package/out/util/langs.js +0 -436
- package/out/util/langs.js.map +0 -1
- package/out/util/license.d.ts +0 -16
- package/out/util/license.js +0 -47
- package/out/util/license.js.map +0 -1
- package/out/util/macosIconComposer.d.ts +0 -10
- package/out/util/macosIconComposer.js +0 -102
- package/out/util/macosIconComposer.js.map +0 -1
- package/out/util/macosVersion.d.ts +0 -3
- package/out/util/macosVersion.js +0 -36
- package/out/util/macosVersion.js.map +0 -1
- package/out/util/macroExpander.d.ts +0 -3
- package/out/util/macroExpander.js +0 -64
- package/out/util/macroExpander.js.map +0 -1
- package/out/util/normalizePackageData.d.ts +0 -1
- package/out/util/normalizePackageData.js +0 -328
- package/out/util/normalizePackageData.js.map +0 -1
- package/out/util/packageDependencies.d.ts +0 -6
- package/out/util/packageDependencies.js +0 -3
- package/out/util/packageDependencies.js.map +0 -1
- package/out/util/packageMetadata.d.ts +0 -1
- package/out/util/packageMetadata.js +0 -124
- package/out/util/packageMetadata.js.map +0 -1
- package/out/util/pathManager.d.ts +0 -3
- package/out/util/pathManager.js +0 -23
- package/out/util/pathManager.js.map +0 -1
- package/out/util/plist.d.ts +0 -7
- package/out/util/plist.js +0 -31
- package/out/util/plist.js.map +0 -1
- package/out/util/rebuild.d.ts +0 -2
- package/out/util/rebuild.js +0 -60
- package/out/util/rebuild.js.map +0 -1
- package/out/util/repositoryInfo.d.ts +0 -3
- package/out/util/repositoryInfo.js +0 -79
- package/out/util/repositoryInfo.js.map +0 -1
- package/out/util/resEdit.d.ts +0 -10
- package/out/util/resEdit.js +0 -49
- package/out/util/resEdit.js.map +0 -1
- package/out/util/resolve.d.ts +0 -2
- package/out/util/resolve.js +0 -59
- package/out/util/resolve.js.map +0 -1
- package/out/util/timer.d.ts +0 -11
- package/out/util/timer.js +0 -28
- package/out/util/timer.js.map +0 -1
- package/out/util/toolsetLock.d.ts +0 -1
- package/out/util/toolsetLock.js +0 -23
- package/out/util/toolsetLock.js.map +0 -1
- package/out/util/yarn.d.ts +0 -22
- package/out/util/yarn.js +0 -160
- package/out/util/yarn.js.map +0 -1
- package/out/version.d.ts +0 -1
- package/out/version.js +0 -5
- package/out/version.js.map +0 -1
- package/out/vm/MonoVm.d.ts +0 -8
- package/out/vm/MonoVm.js +0 -20
- package/out/vm/MonoVm.js.map +0 -1
- package/out/vm/ParallelsVm.d.ts +0 -23
- package/out/vm/ParallelsVm.js +0 -102
- package/out/vm/ParallelsVm.js.map +0 -1
- package/out/vm/PwshVm.d.ts +0 -6
- package/out/vm/PwshVm.js +0 -25
- package/out/vm/PwshVm.js.map +0 -1
- package/out/vm/WineVm.d.ts +0 -12
- package/out/vm/WineVm.js +0 -38
- package/out/vm/WineVm.js.map +0 -1
- package/out/vm/vm.d.ts +0 -14
- package/out/vm/vm.js +0 -88
- package/out/vm/vm.js.map +0 -1
- package/out/winPackager.d.ts +0 -29
- package/out/winPackager.js +0 -271
- package/out/winPackager.js.map +0 -1
- /package/{out → dist}/node-module-collector/types.js.map +0 -0
- /package/{out → dist}/options/FileAssociation.js.map +0 -0
- /package/helpers/{dynamic-import.js → dynamic-import.cjs} +0 -0
|
@@ -1,729 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NsisTarget = void 0;
|
|
4
|
-
const builder_util_1 = require("builder-util");
|
|
5
|
-
const builder_util_runtime_1 = require("builder-util-runtime");
|
|
6
|
-
const debug_1 = require("debug");
|
|
7
|
-
const fs = require("fs");
|
|
8
|
-
const fs_extra_1 = require("fs-extra");
|
|
9
|
-
const path = require("path");
|
|
10
|
-
const core_1 = require("../../core");
|
|
11
|
-
const CommonWindowsInstallerConfiguration_1 = require("../../options/CommonWindowsInstallerConfiguration");
|
|
12
|
-
const platformPackager_1 = require("../../platformPackager");
|
|
13
|
-
const hash_1 = require("../../util/hash");
|
|
14
|
-
const macosVersion_1 = require("../../util/macosVersion");
|
|
15
|
-
const timer_1 = require("../../util/timer");
|
|
16
|
-
const archive_1 = require("../archive");
|
|
17
|
-
const differentialUpdateInfoBuilder_1 = require("../differentialUpdateInfoBuilder");
|
|
18
|
-
const targetUtil_1 = require("../targetUtil");
|
|
19
|
-
const nsisLang_1 = require("./nsisLang");
|
|
20
|
-
const nsisLicense_1 = require("./nsisLicense");
|
|
21
|
-
const nsisScriptGenerator_1 = require("./nsisScriptGenerator");
|
|
22
|
-
const windows_1 = require("../../toolsets/windows");
|
|
23
|
-
const nsisUtil_1 = require("./nsisUtil");
|
|
24
|
-
const nsisValidation_1 = require("./nsisValidation");
|
|
25
|
-
const WineVm_1 = require("../../vm/WineVm");
|
|
26
|
-
const debug = (0, debug_1.default)("electron-builder:nsis");
|
|
27
|
-
// noinspection SpellCheckingInspection
|
|
28
|
-
const ELECTRON_BUILDER_NS_UUID = builder_util_runtime_1.UUID.parse("50e065bc-3134-11e6-9bab-38c9862bdaf3");
|
|
29
|
-
const USE_NSIS_BUILT_IN_COMPRESSOR = false;
|
|
30
|
-
class NsisTarget extends core_1.Target {
|
|
31
|
-
constructor(packager, outDir, targetName, packageHelper) {
|
|
32
|
-
super(targetName);
|
|
33
|
-
this.packager = packager;
|
|
34
|
-
this.outDir = outDir;
|
|
35
|
-
this.packageHelper = packageHelper;
|
|
36
|
-
/** @private */
|
|
37
|
-
this.archs = new Map();
|
|
38
|
-
this.isAsyncSupported = false;
|
|
39
|
-
this.packageHelper.refCount++;
|
|
40
|
-
this.options =
|
|
41
|
-
targetName === "portable"
|
|
42
|
-
? Object.create(null)
|
|
43
|
-
: {
|
|
44
|
-
preCompressedFileExtensions: [".avi", ".mov", ".m4v", ".mp4", ".m4p", ".qt", ".mkv", ".webm", ".vmdk"],
|
|
45
|
-
...this.packager.config.nsis,
|
|
46
|
-
};
|
|
47
|
-
if (targetName !== "nsis") {
|
|
48
|
-
(0, builder_util_runtime_1.deepAssign)(this.options, this.packager.config[targetName === "nsis-web" ? "nsisWeb" : targetName]);
|
|
49
|
-
}
|
|
50
|
-
const deps = packager.info.metadata.dependencies;
|
|
51
|
-
if (deps != null && deps["electron-squirrel-startup"] != null) {
|
|
52
|
-
builder_util_1.log.warn('"electron-squirrel-startup" dependency is not required for NSIS');
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
get shouldBuildUniversalInstaller() {
|
|
56
|
-
const buildSeparateInstallers = this.options.buildUniversalInstaller === false;
|
|
57
|
-
return !buildSeparateInstallers;
|
|
58
|
-
}
|
|
59
|
-
build(appOutDir, arch) {
|
|
60
|
-
this.archs.set(arch, appOutDir);
|
|
61
|
-
if (!this.shouldBuildUniversalInstaller) {
|
|
62
|
-
return this.buildInstaller(new Map().set(arch, appOutDir));
|
|
63
|
-
}
|
|
64
|
-
return Promise.resolve();
|
|
65
|
-
}
|
|
66
|
-
get isBuildDifferentialAware() {
|
|
67
|
-
return !this.isPortable && this.options.differentialPackage !== false;
|
|
68
|
-
}
|
|
69
|
-
getPreCompressedFileExtensions() {
|
|
70
|
-
const result = this.isWebInstaller ? null : this.options.preCompressedFileExtensions;
|
|
71
|
-
return result == null ? null : (0, builder_util_1.asArray)(result).map(it => (it.startsWith(".") ? it : `.${it}`));
|
|
72
|
-
}
|
|
73
|
-
/** @private */
|
|
74
|
-
async buildAppPackage(appOutDir, arch) {
|
|
75
|
-
const options = this.options;
|
|
76
|
-
const packager = this.packager;
|
|
77
|
-
const isBuildDifferentialAware = this.isBuildDifferentialAware;
|
|
78
|
-
const format = !isBuildDifferentialAware && options.useZip ? "zip" : "7z";
|
|
79
|
-
const archiveFile = path.join(this.outDir, `${packager.appInfo.sanitizedName}-${packager.appInfo.version}-${builder_util_1.Arch[arch]}.nsis.${format}`);
|
|
80
|
-
const preCompressedFileExtensions = this.getPreCompressedFileExtensions();
|
|
81
|
-
const archiveOptions = {
|
|
82
|
-
withoutDir: true,
|
|
83
|
-
compression: packager.compression,
|
|
84
|
-
excluded: preCompressedFileExtensions == null ? null : preCompressedFileExtensions.map(it => `*${it}`),
|
|
85
|
-
};
|
|
86
|
-
const timer = (0, timer_1.time)(`nsis package, ${builder_util_1.Arch[arch]}`);
|
|
87
|
-
await (0, archive_1.archive)(format, archiveFile, appOutDir, isBuildDifferentialAware ? (0, differentialUpdateInfoBuilder_1.configureDifferentialAwareArchiveOptions)(archiveOptions) : archiveOptions);
|
|
88
|
-
timer.end();
|
|
89
|
-
if (isBuildDifferentialAware && this.isWebInstaller) {
|
|
90
|
-
const data = await (0, differentialUpdateInfoBuilder_1.appendBlockmap)(archiveFile);
|
|
91
|
-
return {
|
|
92
|
-
...data,
|
|
93
|
-
path: archiveFile,
|
|
94
|
-
};
|
|
95
|
-
}
|
|
96
|
-
else {
|
|
97
|
-
return await createPackageFileInfo(archiveFile);
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
installerFilenamePattern(primaryArch, defaultArch) {
|
|
101
|
-
const setupText = this.isPortable ? "" : "Setup ";
|
|
102
|
-
const archSuffix = !this.shouldBuildUniversalInstaller && primaryArch != null ? (0, builder_util_1.getArchSuffix)(primaryArch, defaultArch) : "";
|
|
103
|
-
return "${productName} " + setupText + "${version}" + archSuffix + ".${ext}";
|
|
104
|
-
}
|
|
105
|
-
get isPortable() {
|
|
106
|
-
return this.name === "portable";
|
|
107
|
-
}
|
|
108
|
-
async finishBuild() {
|
|
109
|
-
if (!this.shouldBuildUniversalInstaller) {
|
|
110
|
-
await super.finishBuild();
|
|
111
|
-
return this.packageHelper.finishBuild();
|
|
112
|
-
}
|
|
113
|
-
try {
|
|
114
|
-
const { pattern } = this.packager.artifactPatternConfig(this.options, this.installerFilenamePattern());
|
|
115
|
-
const builds = new Set([this.archs]);
|
|
116
|
-
if (pattern.includes("${arch}") && this.archs.size > 1) {
|
|
117
|
-
;
|
|
118
|
-
[...this.archs].forEach(([arch, appOutDir]) => builds.add(new Map().set(arch, appOutDir)));
|
|
119
|
-
}
|
|
120
|
-
const doBuildArchs = builds.values();
|
|
121
|
-
for (const archs of doBuildArchs) {
|
|
122
|
-
await this.buildInstaller(archs);
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
finally {
|
|
126
|
-
await super.finishBuild();
|
|
127
|
-
await this.packageHelper.finishBuild();
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
async buildInstaller(archs) {
|
|
131
|
-
var _a, _b, _c;
|
|
132
|
-
const primaryArch = archs.size === 1 ? ((_a = archs.keys().next().value) !== null && _a !== void 0 ? _a : null) : null;
|
|
133
|
-
const packager = this.packager;
|
|
134
|
-
const appInfo = packager.appInfo;
|
|
135
|
-
const options = this.options;
|
|
136
|
-
const defaultArch = (_b = (0, platformPackager_1.chooseNotNull)(this.packager.platformSpecificBuildOptions.defaultArch, this.packager.config.defaultArch)) !== null && _b !== void 0 ? _b : undefined;
|
|
137
|
-
const installerFilename = packager.expandArtifactNamePattern(options, "exe", primaryArch, this.installerFilenamePattern(primaryArch, defaultArch), false, defaultArch);
|
|
138
|
-
const oneClick = options.oneClick !== false;
|
|
139
|
-
const installerPath = path.join(this.outDir, installerFilename);
|
|
140
|
-
const logFields = {
|
|
141
|
-
target: this.name,
|
|
142
|
-
file: builder_util_1.log.filePath(installerPath),
|
|
143
|
-
archs: Array.from(archs.keys())
|
|
144
|
-
.map(it => builder_util_1.Arch[it])
|
|
145
|
-
.join(", "),
|
|
146
|
-
};
|
|
147
|
-
const isPerMachine = options.perMachine === true;
|
|
148
|
-
if (!this.isPortable) {
|
|
149
|
-
logFields.oneClick = oneClick;
|
|
150
|
-
logFields.perMachine = isPerMachine;
|
|
151
|
-
}
|
|
152
|
-
await packager.info.emitArtifactBuildStarted({
|
|
153
|
-
targetPresentableName: this.name,
|
|
154
|
-
file: installerPath,
|
|
155
|
-
arch: primaryArch,
|
|
156
|
-
}, logFields);
|
|
157
|
-
const guid = options.guid || builder_util_runtime_1.UUID.v5(appInfo.id, ELECTRON_BUILDER_NS_UUID);
|
|
158
|
-
const uninstallAppKey = guid.replace(/\\/g, " - ");
|
|
159
|
-
const defines = {
|
|
160
|
-
APP_ID: appInfo.id,
|
|
161
|
-
APP_GUID: guid,
|
|
162
|
-
// Windows bug - entry in Software\Microsoft\Windows\CurrentVersion\Uninstall cannot have \ symbols (dir)
|
|
163
|
-
UNINSTALL_APP_KEY: uninstallAppKey,
|
|
164
|
-
PRODUCT_NAME: appInfo.productName,
|
|
165
|
-
PRODUCT_FILENAME: appInfo.productFilename,
|
|
166
|
-
APP_FILENAME: (0, targetUtil_1.getWindowsInstallationDirName)(appInfo, !oneClick || isPerMachine),
|
|
167
|
-
APP_DESCRIPTION: appInfo.description,
|
|
168
|
-
VERSION: appInfo.version,
|
|
169
|
-
PROJECT_DIR: packager.projectDir,
|
|
170
|
-
BUILD_RESOURCES_DIR: packager.info.buildResourcesDir,
|
|
171
|
-
APP_PACKAGE_NAME: (0, targetUtil_1.getWindowsInstallationAppPackageName)(appInfo.name),
|
|
172
|
-
};
|
|
173
|
-
if ((_c = options.customNsisBinary) === null || _c === void 0 ? void 0 : _c.debugLogging) {
|
|
174
|
-
defines.ENABLE_LOGGING_ELECTRON_BUILDER = null;
|
|
175
|
-
}
|
|
176
|
-
if (uninstallAppKey !== guid) {
|
|
177
|
-
defines.UNINSTALL_REGISTRY_KEY_2 = `Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${guid}`;
|
|
178
|
-
}
|
|
179
|
-
const { homepage } = this.packager.info.metadata;
|
|
180
|
-
(0, builder_util_1.use)(options.uninstallUrlHelp || homepage, it => (defines.UNINSTALL_URL_HELP = it));
|
|
181
|
-
(0, builder_util_1.use)(options.uninstallUrlInfoAbout || homepage, it => (defines.UNINSTALL_URL_INFO_ABOUT = it));
|
|
182
|
-
(0, builder_util_1.use)(options.uninstallUrlUpdateInfo || homepage, it => (defines.UNINSTALL_URL_UPDATE_INFO = it));
|
|
183
|
-
(0, builder_util_1.use)(options.uninstallUrlReadme || homepage, it => (defines.UNINSTALL_URL_README = it));
|
|
184
|
-
const commands = {
|
|
185
|
-
OutFile: `"${installerPath}"`,
|
|
186
|
-
VIProductVersion: appInfo.getVersionInWeirdWindowsForm(),
|
|
187
|
-
VIAddVersionKey: this.computeVersionKey(),
|
|
188
|
-
Unicode: this.isUnicodeEnabled,
|
|
189
|
-
};
|
|
190
|
-
const isPortable = this.isPortable;
|
|
191
|
-
const iconPath = (isPortable ? null : await packager.getResource(options.installerIcon, "installerIcon.ico")) || (await packager.getIconPath());
|
|
192
|
-
if (iconPath != null) {
|
|
193
|
-
if (isPortable) {
|
|
194
|
-
commands.Icon = `"${iconPath}"`;
|
|
195
|
-
}
|
|
196
|
-
else {
|
|
197
|
-
defines.MUI_ICON = iconPath;
|
|
198
|
-
defines.MUI_UNICON = iconPath;
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
const packageFiles = {};
|
|
202
|
-
let estimatedSize = 0;
|
|
203
|
-
if (this.isPortable && options.useZip) {
|
|
204
|
-
for (const [arch, dir] of archs.entries()) {
|
|
205
|
-
defines[arch === builder_util_1.Arch.x64 ? "APP_DIR_64" : arch === builder_util_1.Arch.arm64 ? "APP_DIR_ARM64" : "APP_DIR_32"] = dir;
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
else if (USE_NSIS_BUILT_IN_COMPRESSOR && archs.size === 1) {
|
|
209
|
-
const value = archs.keys().next().value;
|
|
210
|
-
(0, builder_util_1.use)(value, v => (defines.APP_BUILD_DIR = archs.get(v)));
|
|
211
|
-
}
|
|
212
|
-
else {
|
|
213
|
-
await Promise.all(Array.from(archs.keys()).map(async (arch) => {
|
|
214
|
-
const { fileInfo, unpackedSize } = await this.packageHelper.packArch(arch, this);
|
|
215
|
-
const file = fileInfo.path;
|
|
216
|
-
const defineKey = arch === builder_util_1.Arch.x64 ? "APP_64" : arch === builder_util_1.Arch.arm64 ? "APP_ARM64" : "APP_32";
|
|
217
|
-
defines[defineKey] = file;
|
|
218
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
|
|
219
|
-
const defineNameKey = `${defineKey}_NAME`;
|
|
220
|
-
defines[defineNameKey] = path.basename(file);
|
|
221
|
-
// nsis expect a hexadecimal string
|
|
222
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
|
|
223
|
-
const defineHashKey = `${defineKey}_HASH`;
|
|
224
|
-
defines[defineHashKey] = Buffer.from(fileInfo.sha512, "base64").toString("hex").toUpperCase();
|
|
225
|
-
// NSIS accepts size in KiloBytes and supports only whole numbers
|
|
226
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
|
|
227
|
-
const defineUnpackedSizeKey = `${defineKey}_UNPACKED_SIZE`;
|
|
228
|
-
defines[defineUnpackedSizeKey] = Math.ceil(unpackedSize / 1024).toString();
|
|
229
|
-
if (this.isWebInstaller) {
|
|
230
|
-
await packager.info.emitArtifactBuildCompleted({
|
|
231
|
-
file,
|
|
232
|
-
target: this,
|
|
233
|
-
arch,
|
|
234
|
-
packager,
|
|
235
|
-
});
|
|
236
|
-
packageFiles[builder_util_1.Arch[arch]] = fileInfo;
|
|
237
|
-
}
|
|
238
|
-
estimatedSize += unpackedSize;
|
|
239
|
-
}));
|
|
240
|
-
}
|
|
241
|
-
this.configureDefinesForAllTypeOfInstaller(defines);
|
|
242
|
-
if (isPortable) {
|
|
243
|
-
const { unpackDirName, requestExecutionLevel, splashImage } = options;
|
|
244
|
-
defines.REQUEST_EXECUTION_LEVEL = requestExecutionLevel || "user";
|
|
245
|
-
// https://github.com/electron-userland/electron-builder/issues/5764
|
|
246
|
-
if (typeof unpackDirName === "string" || !unpackDirName) {
|
|
247
|
-
defines.UNPACK_DIR_NAME = unpackDirName || (0, builder_util_1.generateKsuid)();
|
|
248
|
-
}
|
|
249
|
-
if (splashImage != null) {
|
|
250
|
-
defines.SPLASH_IMAGE = path.resolve(packager.projectDir, splashImage);
|
|
251
|
-
}
|
|
252
|
-
}
|
|
253
|
-
else {
|
|
254
|
-
await this.configureDefines(oneClick, defines);
|
|
255
|
-
}
|
|
256
|
-
if (estimatedSize !== 0) {
|
|
257
|
-
// in kb
|
|
258
|
-
defines.ESTIMATED_SIZE = Math.round(estimatedSize / 1024);
|
|
259
|
-
}
|
|
260
|
-
if (packager.compression === "store") {
|
|
261
|
-
commands.SetCompress = "off";
|
|
262
|
-
}
|
|
263
|
-
else {
|
|
264
|
-
// difference - 33.540 vs 33.601, only 61 KB (but zip is faster to decompress)
|
|
265
|
-
// do not use /SOLID - "With solid compression, files are uncompressed to temporary file before they are copied to their final destination",
|
|
266
|
-
// it is not good for portable installer (where built-in NSIS compression is used). http://forums.winamp.com/showpost.php?p=2982902&postcount=6
|
|
267
|
-
commands.SetCompressor = "zlib";
|
|
268
|
-
if (!this.isWebInstaller) {
|
|
269
|
-
defines.COMPRESS = "auto";
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
debug(defines);
|
|
273
|
-
debug(commands);
|
|
274
|
-
if (packager.packagerOptions.effectiveOptionComputed != null && (await packager.packagerOptions.effectiveOptionComputed([defines, commands]))) {
|
|
275
|
-
return;
|
|
276
|
-
}
|
|
277
|
-
// prepare short-version variants of defines and commands, to make an uninstaller that doesn't differ much from the previous one
|
|
278
|
-
const definesUninstaller = { ...defines };
|
|
279
|
-
const commandsUninstaller = { ...commands };
|
|
280
|
-
if (appInfo.shortVersion != null) {
|
|
281
|
-
definesUninstaller.VERSION = appInfo.shortVersion;
|
|
282
|
-
commandsUninstaller.VIProductVersion = appInfo.shortVersionWindows;
|
|
283
|
-
commandsUninstaller.VIAddVersionKey = this.computeVersionKey(true);
|
|
284
|
-
}
|
|
285
|
-
this.buildQueueManager.add(async () => {
|
|
286
|
-
const sharedHeader = await this.computeCommonInstallerScriptHeader();
|
|
287
|
-
let rawScript;
|
|
288
|
-
let isCustomScript = false;
|
|
289
|
-
if (isPortable) {
|
|
290
|
-
rawScript = await (0, fs_extra_1.readFile)(path.join(nsisUtil_1.nsisTemplatesDir, "portable.nsi"), "utf8");
|
|
291
|
-
}
|
|
292
|
-
else {
|
|
293
|
-
const result = await this.computeScriptAndSignUninstaller(definesUninstaller, commandsUninstaller, installerPath, sharedHeader, archs);
|
|
294
|
-
rawScript = result.script;
|
|
295
|
-
isCustomScript = result.isCustomScript;
|
|
296
|
-
}
|
|
297
|
-
// copy outfile name into main options, as the computeScriptAndSignUninstaller function was kind enough to add important data to temporary defines.
|
|
298
|
-
defines.UNINSTALLER_OUT_FILE = definesUninstaller.UNINSTALLER_OUT_FILE;
|
|
299
|
-
// Skip size verification for portable (NSIS recompresses the archive, installer < archive is normal)
|
|
300
|
-
// and for custom scripts (may not embed archives).
|
|
301
|
-
await this.executeMakensis(defines, commands, sharedHeader + (await this.computeFinalScript(rawScript, true, archs)), { skipSizeVerification: isPortable || isCustomScript });
|
|
302
|
-
await Promise.all([packager.signIf(installerPath), defines.UNINSTALLER_OUT_FILE == null ? Promise.resolve() : (0, fs_extra_1.unlink)(defines.UNINSTALLER_OUT_FILE)]);
|
|
303
|
-
const safeArtifactName = (0, platformPackager_1.computeSafeArtifactNameIfNeeded)(installerFilename, () => this.generateGitHubInstallerName(primaryArch, defaultArch));
|
|
304
|
-
let updateInfo;
|
|
305
|
-
if (this.isWebInstaller) {
|
|
306
|
-
updateInfo = (0, differentialUpdateInfoBuilder_1.createNsisWebDifferentialUpdateInfo)(installerPath, packageFiles);
|
|
307
|
-
}
|
|
308
|
-
else if (this.isBuildDifferentialAware) {
|
|
309
|
-
updateInfo = await (0, differentialUpdateInfoBuilder_1.createBlockmap)(installerPath, this, packager, safeArtifactName);
|
|
310
|
-
}
|
|
311
|
-
if (updateInfo != null && isPerMachine && (oneClick || options.packElevateHelper)) {
|
|
312
|
-
updateInfo.isAdminRightsRequired = true;
|
|
313
|
-
}
|
|
314
|
-
await packager.info.emitArtifactBuildCompleted({
|
|
315
|
-
file: installerPath,
|
|
316
|
-
updateInfo,
|
|
317
|
-
target: this,
|
|
318
|
-
packager,
|
|
319
|
-
arch: primaryArch,
|
|
320
|
-
safeArtifactName,
|
|
321
|
-
isWriteUpdateInfo: !this.isPortable,
|
|
322
|
-
});
|
|
323
|
-
});
|
|
324
|
-
}
|
|
325
|
-
generateGitHubInstallerName(primaryArch, defaultArch) {
|
|
326
|
-
const appInfo = this.packager.appInfo;
|
|
327
|
-
const classifier = appInfo.name.toLowerCase() === appInfo.name ? "setup-" : "Setup-";
|
|
328
|
-
const archSuffix = !this.shouldBuildUniversalInstaller && primaryArch != null ? (0, builder_util_1.getArchSuffix)(primaryArch, defaultArch) : "";
|
|
329
|
-
return `${appInfo.name}-${this.isPortable ? "" : classifier}${appInfo.version}${archSuffix}.exe`;
|
|
330
|
-
}
|
|
331
|
-
get isUnicodeEnabled() {
|
|
332
|
-
return this.options.unicode !== false;
|
|
333
|
-
}
|
|
334
|
-
get isWebInstaller() {
|
|
335
|
-
return false;
|
|
336
|
-
}
|
|
337
|
-
async computeScriptAndSignUninstaller(defines, commands, installerPath, sharedHeader, archs) {
|
|
338
|
-
var _a;
|
|
339
|
-
const packager = this.packager;
|
|
340
|
-
const customScriptPath = await packager.getResource(this.options.script, "installer.nsi");
|
|
341
|
-
const script = await (0, fs_extra_1.readFile)(customScriptPath || path.join(nsisUtil_1.nsisTemplatesDir, "installer.nsi"), "utf8");
|
|
342
|
-
if (customScriptPath != null) {
|
|
343
|
-
builder_util_1.log.info({ reason: "custom NSIS script is used" }, "uninstaller is not signed by electron-builder");
|
|
344
|
-
return { script, isCustomScript: true };
|
|
345
|
-
}
|
|
346
|
-
// https://github.com/electron-userland/electron-builder/issues/2103
|
|
347
|
-
// it is more safe and reliable to write uninstaller to our out dir
|
|
348
|
-
// to support parallel builds, the uninstaller path must be unique to each target and arch combination
|
|
349
|
-
const uninstallerPath = path.join(this.outDir, `${path.basename(installerPath, "exe")}__uninstaller.exe`);
|
|
350
|
-
const isWin = process.platform === "win32";
|
|
351
|
-
defines.BUILD_UNINSTALLER = null;
|
|
352
|
-
defines.UNINSTALLER_OUT_FILE = isWin ? uninstallerPath : path.win32.join("Z:", uninstallerPath);
|
|
353
|
-
await this.executeMakensis(defines, commands, sharedHeader + (await this.computeFinalScript(script, false, archs)));
|
|
354
|
-
// http://forums.winamp.com/showthread.php?p=3078545
|
|
355
|
-
// TODO: remove workaround when wine is fully upgraded to 11
|
|
356
|
-
if ((0, macosVersion_1.isMacOsCatalina)()) {
|
|
357
|
-
try {
|
|
358
|
-
await nsisUtil_1.UninstallerReader.exec(installerPath, uninstallerPath);
|
|
359
|
-
}
|
|
360
|
-
catch (error) {
|
|
361
|
-
builder_util_1.log.warn(`packager.vm is used: ${error.message}`);
|
|
362
|
-
const vm = await packager.vm.value;
|
|
363
|
-
await vm.exec(installerPath, []);
|
|
364
|
-
// Parallels VM can exit after command execution, but NSIS continue to be running
|
|
365
|
-
let i = 0;
|
|
366
|
-
while (!(await (0, builder_util_1.exists)(uninstallerPath)) && i++ < 100) {
|
|
367
|
-
// noinspection JSUnusedLocalSymbols
|
|
368
|
-
await new Promise((resolve, _reject) => setTimeout(resolve, 300));
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
}
|
|
372
|
-
else {
|
|
373
|
-
const wineVm = new WineVm_1.WineVmManager((_a = packager.config.toolsets) === null || _a === void 0 ? void 0 : _a.wine);
|
|
374
|
-
await wineVm.exec(installerPath, [], { env: { __COMPAT_LAYER: "RunAsInvoker" } });
|
|
375
|
-
}
|
|
376
|
-
await packager.signIf(uninstallerPath);
|
|
377
|
-
delete defines.BUILD_UNINSTALLER;
|
|
378
|
-
// platform-specific path, not wine
|
|
379
|
-
defines.UNINSTALLER_OUT_FILE = uninstallerPath;
|
|
380
|
-
return { script, isCustomScript: false };
|
|
381
|
-
}
|
|
382
|
-
computeVersionKey(short = false) {
|
|
383
|
-
// Error: invalid VIProductVersion format, should be X.X.X.X
|
|
384
|
-
// so, we must strip beta
|
|
385
|
-
const localeId = this.options.language || "1033";
|
|
386
|
-
const appInfo = this.packager.appInfo;
|
|
387
|
-
const versionKey = [
|
|
388
|
-
`/LANG=${localeId} ProductName "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.productName)}"`,
|
|
389
|
-
`/LANG=${localeId} ProductVersion "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.version)}"`,
|
|
390
|
-
`/LANG=${localeId} LegalCopyright "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.copyright)}"`,
|
|
391
|
-
`/LANG=${localeId} FileDescription "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.description)}"`,
|
|
392
|
-
`/LANG=${localeId} FileVersion "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.buildVersion)}"`,
|
|
393
|
-
];
|
|
394
|
-
if (short) {
|
|
395
|
-
versionKey[1] = `/LANG=${localeId} ProductVersion "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.shortVersion)}"`;
|
|
396
|
-
versionKey[4] = `/LANG=${localeId} FileVersion "${(0, nsisScriptGenerator_1.nsisEscapeString)(appInfo.shortVersion)}"`;
|
|
397
|
-
}
|
|
398
|
-
(0, builder_util_1.use)(this.packager.platformSpecificBuildOptions.legalTrademarks, it => versionKey.push(`/LANG=${localeId} LegalTrademarks "${(0, nsisScriptGenerator_1.nsisEscapeString)(it)}"`));
|
|
399
|
-
(0, builder_util_1.use)(appInfo.companyName, it => versionKey.push(`/LANG=${localeId} CompanyName "${(0, nsisScriptGenerator_1.nsisEscapeString)(it)}"`));
|
|
400
|
-
return versionKey;
|
|
401
|
-
}
|
|
402
|
-
configureDefines(oneClick, defines) {
|
|
403
|
-
const packager = this.packager;
|
|
404
|
-
const options = this.options;
|
|
405
|
-
const asyncTaskManager = new builder_util_1.AsyncTaskManager(packager.info.cancellationToken);
|
|
406
|
-
if (oneClick) {
|
|
407
|
-
defines.ONE_CLICK = null;
|
|
408
|
-
if (options.runAfterFinish !== false) {
|
|
409
|
-
defines.RUN_AFTER_FINISH = null;
|
|
410
|
-
}
|
|
411
|
-
asyncTaskManager.add(async () => {
|
|
412
|
-
const installerHeaderIcon = await packager.getResource(options.installerHeaderIcon, "installerHeaderIcon.ico");
|
|
413
|
-
if (installerHeaderIcon != null) {
|
|
414
|
-
defines.HEADER_ICO = installerHeaderIcon;
|
|
415
|
-
}
|
|
416
|
-
});
|
|
417
|
-
}
|
|
418
|
-
else {
|
|
419
|
-
if (options.runAfterFinish === false) {
|
|
420
|
-
defines.HIDE_RUN_AFTER_FINISH = null;
|
|
421
|
-
}
|
|
422
|
-
asyncTaskManager.add(async () => {
|
|
423
|
-
const installerHeader = await packager.getResource(options.installerHeader, "installerHeader.bmp");
|
|
424
|
-
if (installerHeader != null) {
|
|
425
|
-
defines.MUI_HEADERIMAGE = null;
|
|
426
|
-
defines.MUI_HEADERIMAGE_RIGHT = null;
|
|
427
|
-
defines.MUI_HEADERIMAGE_BITMAP = installerHeader;
|
|
428
|
-
}
|
|
429
|
-
});
|
|
430
|
-
asyncTaskManager.add(async () => {
|
|
431
|
-
const bitmap = (await packager.getResource(options.installerSidebar, "installerSidebar.bmp")) || "${NSISDIR}\\Contrib\\Graphics\\Wizard\\nsis3-metro.bmp";
|
|
432
|
-
defines.MUI_WELCOMEFINISHPAGE_BITMAP = bitmap;
|
|
433
|
-
defines.MUI_UNWELCOMEFINISHPAGE_BITMAP = (await packager.getResource(options.uninstallerSidebar, "uninstallerSidebar.bmp")) || bitmap;
|
|
434
|
-
});
|
|
435
|
-
if (options.allowElevation !== false) {
|
|
436
|
-
defines.MULTIUSER_INSTALLMODE_ALLOW_ELEVATION = null;
|
|
437
|
-
}
|
|
438
|
-
}
|
|
439
|
-
if (options.perMachine === true) {
|
|
440
|
-
defines.INSTALL_MODE_PER_ALL_USERS = null;
|
|
441
|
-
}
|
|
442
|
-
if (options.selectPerMachineByDefault === true) {
|
|
443
|
-
defines.INSTALL_MODE_PER_ALL_USERS_DEFAULT = null;
|
|
444
|
-
}
|
|
445
|
-
if (!oneClick || options.perMachine === true) {
|
|
446
|
-
defines.INSTALL_MODE_PER_ALL_USERS_REQUIRED = null;
|
|
447
|
-
}
|
|
448
|
-
if (options.allowToChangeInstallationDirectory) {
|
|
449
|
-
if (oneClick) {
|
|
450
|
-
throw new builder_util_1.InvalidConfigurationError("allowToChangeInstallationDirectory makes sense only for assisted installer (please set oneClick to false)");
|
|
451
|
-
}
|
|
452
|
-
defines.allowToChangeInstallationDirectory = null;
|
|
453
|
-
}
|
|
454
|
-
if (options.removeDefaultUninstallWelcomePage) {
|
|
455
|
-
defines.removeDefaultUninstallWelcomePage = null;
|
|
456
|
-
}
|
|
457
|
-
const commonOptions = (0, CommonWindowsInstallerConfiguration_1.getEffectiveOptions)(options, packager);
|
|
458
|
-
if (commonOptions.menuCategory != null) {
|
|
459
|
-
defines.MENU_FILENAME = commonOptions.menuCategory;
|
|
460
|
-
}
|
|
461
|
-
defines.SHORTCUT_NAME = commonOptions.shortcutName;
|
|
462
|
-
if (options.deleteAppDataOnUninstall) {
|
|
463
|
-
defines.DELETE_APP_DATA_ON_UNINSTALL = null;
|
|
464
|
-
}
|
|
465
|
-
asyncTaskManager.add(async () => {
|
|
466
|
-
const uninstallerIcon = await packager.getResource(options.uninstallerIcon, "uninstallerIcon.ico");
|
|
467
|
-
if (uninstallerIcon != null) {
|
|
468
|
-
// we don't need to copy MUI_UNICON (defaults to app icon), so, we have 2 defines
|
|
469
|
-
defines.UNINSTALLER_ICON = uninstallerIcon;
|
|
470
|
-
defines.MUI_UNICON = uninstallerIcon;
|
|
471
|
-
}
|
|
472
|
-
});
|
|
473
|
-
defines.UNINSTALL_DISPLAY_NAME = packager.expandMacro(options.uninstallDisplayName || "${productName} ${version}", null, {}, false);
|
|
474
|
-
if (commonOptions.isCreateDesktopShortcut === CommonWindowsInstallerConfiguration_1.DesktopShortcutCreationPolicy.NEVER) {
|
|
475
|
-
defines.DO_NOT_CREATE_DESKTOP_SHORTCUT = null;
|
|
476
|
-
}
|
|
477
|
-
if (commonOptions.isCreateDesktopShortcut === CommonWindowsInstallerConfiguration_1.DesktopShortcutCreationPolicy.ALWAYS) {
|
|
478
|
-
defines.RECREATE_DESKTOP_SHORTCUT = null;
|
|
479
|
-
}
|
|
480
|
-
if (!commonOptions.isCreateStartMenuShortcut) {
|
|
481
|
-
defines.DO_NOT_CREATE_START_MENU_SHORTCUT = null;
|
|
482
|
-
}
|
|
483
|
-
if (options.displayLanguageSelector === true) {
|
|
484
|
-
defines.DISPLAY_LANG_SELECTOR = null;
|
|
485
|
-
}
|
|
486
|
-
return asyncTaskManager.awaitTasks();
|
|
487
|
-
}
|
|
488
|
-
configureDefinesForAllTypeOfInstaller(defines) {
|
|
489
|
-
const appInfo = this.packager.appInfo;
|
|
490
|
-
const companyName = appInfo.companyName;
|
|
491
|
-
if (companyName != null) {
|
|
492
|
-
defines.COMPANY_NAME = companyName;
|
|
493
|
-
}
|
|
494
|
-
// electron uses product file name as app data, define it as well to remove on uninstall
|
|
495
|
-
if (defines.APP_FILENAME !== appInfo.productFilename) {
|
|
496
|
-
defines.APP_PRODUCT_FILENAME = appInfo.productFilename;
|
|
497
|
-
}
|
|
498
|
-
if (this.isWebInstaller) {
|
|
499
|
-
defines.APP_PACKAGE_STORE_FILE = `${appInfo.updaterCacheDirName}\\${builder_util_runtime_1.CURRENT_APP_PACKAGE_FILE_NAME}`;
|
|
500
|
-
}
|
|
501
|
-
else {
|
|
502
|
-
defines.APP_INSTALLER_STORE_FILE = `${appInfo.updaterCacheDirName}\\${builder_util_runtime_1.CURRENT_APP_INSTALLER_FILE_NAME}`;
|
|
503
|
-
}
|
|
504
|
-
if (!this.isWebInstaller && defines.APP_BUILD_DIR == null) {
|
|
505
|
-
const options = this.options;
|
|
506
|
-
if (options.useZip) {
|
|
507
|
-
defines.ZIP_COMPRESSION = null;
|
|
508
|
-
}
|
|
509
|
-
defines.COMPRESSION_METHOD = options.useZip ? "zip" : "7z";
|
|
510
|
-
}
|
|
511
|
-
}
|
|
512
|
-
async executeMakensis(defines, commands, script, opts = {}) {
|
|
513
|
-
var _a, _b;
|
|
514
|
-
const args = this.options.warningsAsErrors === false ? [] : ["-WX"];
|
|
515
|
-
args.push("-INPUTCHARSET", "UTF8");
|
|
516
|
-
for (const name of Object.keys(defines)) {
|
|
517
|
-
const value = defines[name];
|
|
518
|
-
if (value == null) {
|
|
519
|
-
args.push(`-D${name}`);
|
|
520
|
-
}
|
|
521
|
-
else {
|
|
522
|
-
// nsisEscapeString prevents three classes of injection:
|
|
523
|
-
// 1. Newlines → replaced with spaces; a bare \n in a define value
|
|
524
|
-
// would terminate the current script line and let whatever follows
|
|
525
|
-
// be parsed as a new preprocessor directive (e.g. !system, !include).
|
|
526
|
-
// 2. bare $ → escaped to $$; unescaped $ in a define value would cause
|
|
527
|
-
// NSIS to expand an unintended variable reference. ${...} references
|
|
528
|
-
// are left intact so NSIS compile-time defines like ${NSISDIR} still
|
|
529
|
-
// expand correctly.
|
|
530
|
-
// 3. " chars → escaped to $\"; an unescaped " would break out of
|
|
531
|
-
// double-quoted NSIS string literals where ${DEFINE} is expanded.
|
|
532
|
-
args.push(`-D${name}=${(0, nsisScriptGenerator_1.nsisEscapeString)(String(value))}`);
|
|
533
|
-
}
|
|
534
|
-
}
|
|
535
|
-
for (const name of Object.keys(commands)) {
|
|
536
|
-
const value = commands[name];
|
|
537
|
-
if (Array.isArray(value)) {
|
|
538
|
-
for (const c of value) {
|
|
539
|
-
args.push(`-X${name} ${c}`);
|
|
540
|
-
}
|
|
541
|
-
}
|
|
542
|
-
else {
|
|
543
|
-
args.push(`-X${name} ${value}`);
|
|
544
|
-
}
|
|
545
|
-
}
|
|
546
|
-
args.push("-");
|
|
547
|
-
if (this.packager.debugLogger.isEnabled) {
|
|
548
|
-
this.packager.debugLogger.add("nsis.script", script);
|
|
549
|
-
}
|
|
550
|
-
if (process.platform === "win32") {
|
|
551
|
-
// fix for an issue caused by virus scanners, locking the file during write
|
|
552
|
-
// https://github.com/electron-userland/electron-builder/issues/5005
|
|
553
|
-
await ensureNotBusy(commands["OutFile"].replace(/"/g, ""));
|
|
554
|
-
}
|
|
555
|
-
const makensis = await (0, windows_1.getMakeNsisPath)((_a = this.packager.config.toolsets) === null || _a === void 0 ? void 0 : _a.nsis, this.options.customNsisBinary);
|
|
556
|
-
const { stdout, stderr } = await (0, builder_util_1.spawnAndWriteWithOutput)(makensis.path, args, script, {
|
|
557
|
-
env: { ...process.env, ...((_b = makensis.env) !== null && _b !== void 0 ? _b : {}) },
|
|
558
|
-
cwd: nsisUtil_1.nsisTemplatesDir,
|
|
559
|
-
});
|
|
560
|
-
(0, nsisValidation_1.checkMakensisOutput)(stdout, stderr);
|
|
561
|
-
// Only verify output size for the final, non-web installer.
|
|
562
|
-
// BUILD_UNINSTALLER: intermediate uninstaller build — no embedded archives.
|
|
563
|
-
// APP_PACKAGE_STORE_FILE: nsis-web — archives downloaded at install-time.
|
|
564
|
-
// skipSizeVerification: portable builds (NSIS recompresses the archive, so
|
|
565
|
-
// installer < archive_size is normal) and custom scripts (may not embed archives).
|
|
566
|
-
if (!("BUILD_UNINSTALLER" in defines) && !("APP_PACKAGE_STORE_FILE" in defines) && !opts.skipSizeVerification) {
|
|
567
|
-
const outFile = commands["OutFile"].replace(/^"|"$/g, "");
|
|
568
|
-
await (0, nsisValidation_1.verifyInstallerSize)(outFile, defines);
|
|
569
|
-
}
|
|
570
|
-
}
|
|
571
|
-
async computeCommonInstallerScriptHeader() {
|
|
572
|
-
const packager = this.packager;
|
|
573
|
-
const options = this.options;
|
|
574
|
-
const scriptGenerator = new nsisScriptGenerator_1.NsisScriptGenerator();
|
|
575
|
-
const langConfigurator = new nsisLang_1.LangConfigurator(options);
|
|
576
|
-
scriptGenerator.include(path.join(nsisUtil_1.nsisTemplatesDir, "include", "StdUtils.nsh"));
|
|
577
|
-
const includeDir = path.join(nsisUtil_1.nsisTemplatesDir, "include");
|
|
578
|
-
scriptGenerator.addIncludeDir(includeDir);
|
|
579
|
-
scriptGenerator.flags(["updated", "force-run", "keep-shortcuts", "no-desktop-shortcut", "delete-app-data", "allusers", "currentuser"]);
|
|
580
|
-
(0, nsisLang_1.createAddLangsMacro)(scriptGenerator, langConfigurator);
|
|
581
|
-
const taskManager = new builder_util_1.AsyncTaskManager(packager.info.cancellationToken);
|
|
582
|
-
const pluginArch = this.isUnicodeEnabled ? "x86-unicode" : "x86-ansi";
|
|
583
|
-
taskManager.add(async () => {
|
|
584
|
-
var _a;
|
|
585
|
-
scriptGenerator.addPluginDir(pluginArch, path.join(await (0, windows_1.getNsisPluginsPath)((_a = this.packager.config.toolsets) === null || _a === void 0 ? void 0 : _a.nsis, this.options.customNsisResources), pluginArch));
|
|
586
|
-
});
|
|
587
|
-
taskManager.add(async () => {
|
|
588
|
-
const userPluginDir = path.join(packager.info.buildResourcesDir, pluginArch);
|
|
589
|
-
const stat = await (0, builder_util_1.statOrNull)(userPluginDir);
|
|
590
|
-
if (stat != null && stat.isDirectory()) {
|
|
591
|
-
scriptGenerator.addPluginDir(pluginArch, userPluginDir);
|
|
592
|
-
}
|
|
593
|
-
});
|
|
594
|
-
taskManager.addTask((0, nsisLang_1.addCustomMessageFileInclude)("messages.yml", packager, scriptGenerator, langConfigurator));
|
|
595
|
-
if (!this.isPortable) {
|
|
596
|
-
if (options.oneClick === false) {
|
|
597
|
-
taskManager.addTask((0, nsisLang_1.addCustomMessageFileInclude)("assistedMessages.yml", packager, scriptGenerator, langConfigurator));
|
|
598
|
-
}
|
|
599
|
-
taskManager.add(async () => {
|
|
600
|
-
const customInclude = await packager.getResource(this.options.include, "installer.nsh");
|
|
601
|
-
if (customInclude != null) {
|
|
602
|
-
scriptGenerator.addIncludeDir(packager.info.buildResourcesDir);
|
|
603
|
-
scriptGenerator.include(customInclude);
|
|
604
|
-
}
|
|
605
|
-
});
|
|
606
|
-
}
|
|
607
|
-
await taskManager.awaitTasks();
|
|
608
|
-
return scriptGenerator.build();
|
|
609
|
-
}
|
|
610
|
-
async computeFinalScript(originalScript, isInstaller, archs) {
|
|
611
|
-
const packager = this.packager;
|
|
612
|
-
const options = this.options;
|
|
613
|
-
const langConfigurator = new nsisLang_1.LangConfigurator(options);
|
|
614
|
-
const scriptGenerator = new nsisScriptGenerator_1.NsisScriptGenerator();
|
|
615
|
-
const taskManager = new builder_util_1.AsyncTaskManager(packager.info.cancellationToken);
|
|
616
|
-
if (isInstaller) {
|
|
617
|
-
// http://stackoverflow.com/questions/997456/nsis-license-file-based-on-language-selection
|
|
618
|
-
taskManager.add(() => (0, nsisLicense_1.computeLicensePage)(packager, options, scriptGenerator, langConfigurator.langs));
|
|
619
|
-
}
|
|
620
|
-
await taskManager.awaitTasks();
|
|
621
|
-
if (this.isPortable) {
|
|
622
|
-
return scriptGenerator.build() + originalScript;
|
|
623
|
-
}
|
|
624
|
-
const preCompressedFileExtensions = this.getPreCompressedFileExtensions();
|
|
625
|
-
if (preCompressedFileExtensions != null && preCompressedFileExtensions.length !== 0) {
|
|
626
|
-
for (const [arch, dir] of archs.entries()) {
|
|
627
|
-
await generateForPreCompressed(preCompressedFileExtensions, dir, arch, scriptGenerator);
|
|
628
|
-
}
|
|
629
|
-
}
|
|
630
|
-
const fileAssociations = packager.fileAssociations;
|
|
631
|
-
if (fileAssociations.length !== 0) {
|
|
632
|
-
scriptGenerator.include(path.join(path.join(nsisUtil_1.nsisTemplatesDir, "include"), "FileAssociation.nsh"));
|
|
633
|
-
if (isInstaller) {
|
|
634
|
-
const registerFileAssociationsScript = new nsisScriptGenerator_1.NsisScriptGenerator();
|
|
635
|
-
for (const item of fileAssociations) {
|
|
636
|
-
const extensions = (0, builder_util_1.asArray)(item.ext).map(platformPackager_1.normalizeExt);
|
|
637
|
-
for (const ext of extensions) {
|
|
638
|
-
const customIcon = await packager.getResource((0, builder_util_1.getPlatformIconFileName)(item.icon, false), `${extensions[0]}.ico`);
|
|
639
|
-
let installedIconPath = "$appExe,0";
|
|
640
|
-
if (customIcon != null) {
|
|
641
|
-
installedIconPath = `$INSTDIR\\resources\\${(0, nsisScriptGenerator_1.nsisEscapeString)(path.basename(customIcon))}`;
|
|
642
|
-
registerFileAssociationsScript.file(installedIconPath, customIcon);
|
|
643
|
-
}
|
|
644
|
-
const icon = `"${installedIconPath}"`;
|
|
645
|
-
const commandText = `"Open with ${(0, nsisScriptGenerator_1.nsisEscapeString)(packager.appInfo.productName)}"`;
|
|
646
|
-
const command = '"$appExe $\\"%1$\\""';
|
|
647
|
-
registerFileAssociationsScript.insertMacro("APP_ASSOCIATE", `"${(0, nsisScriptGenerator_1.nsisEscapeString)(ext)}" "${(0, nsisScriptGenerator_1.nsisEscapeString)(item.name || ext)}" "${(0, nsisScriptGenerator_1.nsisEscapeString)(item.description || "")}" ${icon} ${commandText} ${command}`);
|
|
648
|
-
}
|
|
649
|
-
}
|
|
650
|
-
scriptGenerator.macro("registerFileAssociations", registerFileAssociationsScript);
|
|
651
|
-
}
|
|
652
|
-
else {
|
|
653
|
-
const unregisterFileAssociationsScript = new nsisScriptGenerator_1.NsisScriptGenerator();
|
|
654
|
-
for (const item of fileAssociations) {
|
|
655
|
-
for (const ext of (0, builder_util_1.asArray)(item.ext)) {
|
|
656
|
-
unregisterFileAssociationsScript.insertMacro("APP_UNASSOCIATE", `"${(0, platformPackager_1.normalizeExt)(ext)}" "${item.name || ext}"`);
|
|
657
|
-
}
|
|
658
|
-
}
|
|
659
|
-
scriptGenerator.macro("unregisterFileAssociations", unregisterFileAssociationsScript);
|
|
660
|
-
}
|
|
661
|
-
}
|
|
662
|
-
return scriptGenerator.build() + originalScript;
|
|
663
|
-
}
|
|
664
|
-
}
|
|
665
|
-
exports.NsisTarget = NsisTarget;
|
|
666
|
-
async function generateForPreCompressed(preCompressedFileExtensions, dir, arch, scriptGenerator) {
|
|
667
|
-
const resourcesDir = path.join(dir, "resources");
|
|
668
|
-
const dirInfo = await (0, builder_util_1.statOrNull)(resourcesDir);
|
|
669
|
-
if (dirInfo == null || !dirInfo.isDirectory()) {
|
|
670
|
-
return;
|
|
671
|
-
}
|
|
672
|
-
const nodeModules = `${path.sep}node_modules`;
|
|
673
|
-
const preCompressedAssets = await (0, builder_util_1.walk)(resourcesDir, (file, stat) => {
|
|
674
|
-
if (stat.isDirectory()) {
|
|
675
|
-
return !file.endsWith(nodeModules);
|
|
676
|
-
}
|
|
677
|
-
else {
|
|
678
|
-
return preCompressedFileExtensions.some(it => file.endsWith(it));
|
|
679
|
-
}
|
|
680
|
-
});
|
|
681
|
-
if (preCompressedAssets.length !== 0) {
|
|
682
|
-
const macro = new nsisScriptGenerator_1.NsisScriptGenerator();
|
|
683
|
-
for (const file of preCompressedAssets) {
|
|
684
|
-
macro.file(`$INSTDIR\\${(0, nsisScriptGenerator_1.nsisEscapeString)(path.relative(dir, file).replace(/\//g, "\\"))}`, file);
|
|
685
|
-
}
|
|
686
|
-
scriptGenerator.macro(`customFiles_${builder_util_1.Arch[arch]}`, macro);
|
|
687
|
-
}
|
|
688
|
-
}
|
|
689
|
-
async function ensureNotBusy(outFile) {
|
|
690
|
-
function isBusy(wasBusyBefore) {
|
|
691
|
-
return new Promise((resolve, reject) => {
|
|
692
|
-
fs.open(outFile, "r+", (error, fd) => {
|
|
693
|
-
try {
|
|
694
|
-
if (error != null && error.code === "EBUSY") {
|
|
695
|
-
if (!wasBusyBefore) {
|
|
696
|
-
builder_util_1.log.info({}, "output file is locked for writing (maybe by virus scanner) => waiting for unlock...");
|
|
697
|
-
}
|
|
698
|
-
resolve(false);
|
|
699
|
-
}
|
|
700
|
-
else if (fd == null) {
|
|
701
|
-
resolve(true);
|
|
702
|
-
}
|
|
703
|
-
else {
|
|
704
|
-
fs.close(fd, () => resolve(true));
|
|
705
|
-
}
|
|
706
|
-
}
|
|
707
|
-
catch (error) {
|
|
708
|
-
reject(error);
|
|
709
|
-
}
|
|
710
|
-
});
|
|
711
|
-
}).then(result => {
|
|
712
|
-
if (result) {
|
|
713
|
-
return true;
|
|
714
|
-
}
|
|
715
|
-
else {
|
|
716
|
-
return new Promise(resolve => setTimeout(resolve, 2000)).then(() => isBusy(true));
|
|
717
|
-
}
|
|
718
|
-
});
|
|
719
|
-
}
|
|
720
|
-
await isBusy(false);
|
|
721
|
-
}
|
|
722
|
-
async function createPackageFileInfo(file) {
|
|
723
|
-
return {
|
|
724
|
-
path: file,
|
|
725
|
-
size: (await (0, fs_extra_1.stat)(file)).size,
|
|
726
|
-
sha512: await (0, hash_1.hashFile)(file),
|
|
727
|
-
};
|
|
728
|
-
}
|
|
729
|
-
//# sourceMappingURL=NsisTarget.js.map
|