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.
Files changed (997) hide show
  1. package/dist/Framework.d.ts +40 -0
  2. package/dist/Framework.d.ts.map +1 -0
  3. package/dist/Framework.js +4 -0
  4. package/dist/Framework.js.map +1 -0
  5. package/dist/appInfo.d.ts +32 -0
  6. package/dist/appInfo.d.ts.map +1 -0
  7. package/dist/appInfo.js +145 -0
  8. package/dist/appInfo.js.map +1 -0
  9. package/dist/asar/asar.d.ts +39 -0
  10. package/dist/asar/asar.d.ts.map +1 -0
  11. package/dist/asar/asar.js +155 -0
  12. package/dist/asar/asar.js.map +1 -0
  13. package/dist/asar/asarFileChecker.d.ts +3 -0
  14. package/dist/asar/asarFileChecker.d.ts.map +1 -0
  15. package/dist/asar/asarFileChecker.js +22 -0
  16. package/dist/asar/asarFileChecker.js.map +1 -0
  17. package/dist/asar/asarUtil.d.ts +2 -0
  18. package/dist/asar/asarUtil.d.ts.map +1 -0
  19. package/dist/asar/asarUtil.js +278 -0
  20. package/dist/asar/asarUtil.js.map +1 -0
  21. package/dist/asar/integrity.d.ts +16 -0
  22. package/dist/asar/integrity.d.ts.map +1 -0
  23. package/dist/asar/integrity.js +59 -0
  24. package/dist/asar/integrity.js.map +1 -0
  25. package/dist/asar/unpackDetector.d.ts +2 -0
  26. package/dist/asar/unpackDetector.d.ts.map +1 -0
  27. package/dist/asar/unpackDetector.js +39 -0
  28. package/dist/asar/unpackDetector.js.map +1 -0
  29. package/dist/codeSign/certInfo.d.ts +55 -0
  30. package/dist/codeSign/certInfo.d.ts.map +1 -0
  31. package/dist/codeSign/certInfo.js +459 -0
  32. package/dist/codeSign/certInfo.js.map +1 -0
  33. package/dist/codeSign/codesign.d.ts +4 -0
  34. package/dist/codeSign/codesign.d.ts.map +1 -0
  35. package/dist/codeSign/codesign.js +32 -0
  36. package/dist/codeSign/codesign.js.map +1 -0
  37. package/dist/codeSign/mac/macCodeSign.d.ts +29 -0
  38. package/dist/codeSign/mac/macCodeSign.d.ts.map +1 -0
  39. package/dist/codeSign/mac/macCodeSign.js +273 -0
  40. package/dist/codeSign/mac/macCodeSign.js.map +1 -0
  41. package/dist/codeSign/signManager.d.ts +14 -0
  42. package/dist/codeSign/signManager.d.ts.map +1 -0
  43. package/dist/codeSign/signManager.js +2 -0
  44. package/dist/codeSign/signManager.js.map +1 -0
  45. package/dist/codeSign/win/windowsCodeSign.d.ts +8 -0
  46. package/dist/codeSign/win/windowsCodeSign.d.ts.map +1 -0
  47. package/dist/codeSign/win/windowsCodeSign.js +34 -0
  48. package/dist/codeSign/win/windowsCodeSign.js.map +1 -0
  49. package/dist/codeSign/win/windowsSignAzureManager.d.ts +18 -0
  50. package/dist/codeSign/win/windowsSignAzureManager.d.ts.map +1 -0
  51. package/dist/codeSign/win/windowsSignAzureManager.js +68 -0
  52. package/dist/codeSign/win/windowsSignAzureManager.js.map +1 -0
  53. package/dist/codeSign/win/windowsSignToolManager.d.ts +59 -0
  54. package/dist/codeSign/win/windowsSignToolManager.d.ts.map +1 -0
  55. package/dist/codeSign/win/windowsSignToolManager.js +364 -0
  56. package/dist/codeSign/win/windowsSignToolManager.js.map +1 -0
  57. package/dist/configuration.d.ts +1010 -0
  58. package/dist/configuration.d.ts.map +1 -0
  59. package/dist/configuration.js +2 -0
  60. package/dist/configuration.js.map +1 -0
  61. package/dist/core.d.ts +61 -0
  62. package/dist/core.d.ts.map +1 -0
  63. package/dist/core.js +61 -0
  64. package/dist/core.js.map +1 -0
  65. package/dist/electron/ElectronFramework.d.ts +17 -0
  66. package/dist/electron/ElectronFramework.d.ts.map +1 -0
  67. package/dist/electron/ElectronFramework.js +236 -0
  68. package/dist/electron/ElectronFramework.js.map +1 -0
  69. package/dist/electron/electronVersion.d.ts +7 -0
  70. package/dist/electron/electronVersion.d.ts.map +1 -0
  71. package/dist/electron/electronVersion.js +119 -0
  72. package/dist/electron/electronVersion.js.map +1 -0
  73. package/dist/electron/injectFFMPEG.d.ts +12 -0
  74. package/dist/electron/injectFFMPEG.d.ts.map +1 -0
  75. package/dist/electron/injectFFMPEG.js +53 -0
  76. package/dist/electron/injectFFMPEG.js.map +1 -0
  77. package/dist/electron/mac/electronMac.d.ts +2 -0
  78. package/dist/electron/mac/electronMac.d.ts.map +1 -0
  79. package/dist/electron/mac/electronMac.js +254 -0
  80. package/dist/electron/mac/electronMac.js.map +1 -0
  81. package/dist/electron/search-module.d.ts +24 -0
  82. package/dist/electron/search-module.d.ts.map +1 -0
  83. package/dist/electron/search-module.js +68 -0
  84. package/dist/electron/search-module.js.map +1 -0
  85. package/dist/electron/win/electronWin.d.ts +2 -0
  86. package/dist/electron/win/electronWin.d.ts.map +1 -0
  87. package/dist/electron/win/electronWin.js +36 -0
  88. package/dist/electron/win/electronWin.js.map +1 -0
  89. package/dist/errorMessages.d.ts +2 -0
  90. package/dist/errorMessages.d.ts.map +1 -0
  91. package/dist/errorMessages.js +8 -0
  92. package/dist/errorMessages.js.map +1 -0
  93. package/dist/fileMatcher.d.ts +31 -0
  94. package/dist/fileMatcher.d.ts.map +1 -0
  95. package/dist/fileMatcher.js +277 -0
  96. package/dist/fileMatcher.js.map +1 -0
  97. package/dist/fileTransformer.d.ts +2 -0
  98. package/dist/fileTransformer.d.ts.map +1 -0
  99. package/dist/fileTransformer.js +82 -0
  100. package/dist/fileTransformer.js.map +1 -0
  101. package/dist/forge-maker.d.ts +6 -0
  102. package/dist/forge-maker.d.ts.map +1 -0
  103. package/dist/forge-maker.js +20 -0
  104. package/dist/forge-maker.js.map +1 -0
  105. package/dist/index.d.ts +40 -0
  106. package/dist/index.d.ts.map +1 -0
  107. package/dist/index.js +77 -0
  108. package/dist/index.js.map +1 -0
  109. package/dist/indexInternal.d.ts +46 -0
  110. package/dist/indexInternal.d.ts.map +1 -0
  111. package/dist/indexInternal.js +39 -0
  112. package/dist/indexInternal.js.map +1 -0
  113. package/dist/linuxPackager.d.ts +13 -0
  114. package/dist/linuxPackager.d.ts.map +1 -0
  115. package/dist/linuxPackager.js +75 -0
  116. package/dist/linuxPackager.js.map +1 -0
  117. package/dist/macPackager.d.ts +50 -0
  118. package/dist/macPackager.d.ts.map +1 -0
  119. package/dist/macPackager.js +442 -0
  120. package/dist/macPackager.js.map +1 -0
  121. package/dist/node-module-collector/bunNodeModulesCollector.d.ts +11 -0
  122. package/dist/node-module-collector/bunNodeModulesCollector.d.ts.map +1 -0
  123. package/dist/node-module-collector/bunNodeModulesCollector.js +14 -0
  124. package/dist/node-module-collector/bunNodeModulesCollector.js.map +1 -0
  125. package/dist/node-module-collector/hoist.d.ts +124 -0
  126. package/dist/node-module-collector/hoist.d.ts.map +1 -0
  127. package/dist/node-module-collector/hoist.js +880 -0
  128. package/dist/node-module-collector/hoist.js.map +1 -0
  129. package/dist/node-module-collector/index.d.ts +21 -0
  130. package/dist/node-module-collector/index.d.ts.map +1 -0
  131. package/dist/node-module-collector/index.js +124 -0
  132. package/dist/node-module-collector/index.js.map +1 -0
  133. package/dist/node-module-collector/moduleManager.d.ts +94 -0
  134. package/dist/node-module-collector/moduleManager.d.ts.map +1 -0
  135. package/dist/node-module-collector/moduleManager.js +314 -0
  136. package/dist/node-module-collector/moduleManager.js.map +1 -0
  137. package/dist/node-module-collector/nodeModulesCollector.d.ts +138 -0
  138. package/dist/node-module-collector/nodeModulesCollector.d.ts.map +1 -0
  139. package/dist/node-module-collector/nodeModulesCollector.js +421 -0
  140. package/dist/node-module-collector/nodeModulesCollector.js.map +1 -0
  141. package/dist/node-module-collector/npmNodeModulesCollector.d.ts +15 -0
  142. package/dist/node-module-collector/npmNodeModulesCollector.d.ts.map +1 -0
  143. package/dist/node-module-collector/npmNodeModulesCollector.js +75 -0
  144. package/dist/node-module-collector/npmNodeModulesCollector.js.map +1 -0
  145. package/dist/node-module-collector/packageManager.d.ts +18 -0
  146. package/dist/node-module-collector/packageManager.d.ts.map +1 -0
  147. package/dist/node-module-collector/packageManager.js +137 -0
  148. package/dist/node-module-collector/packageManager.js.map +1 -0
  149. package/dist/node-module-collector/pnpmNodeModulesCollector.d.ts +45 -0
  150. package/dist/node-module-collector/pnpmNodeModulesCollector.d.ts.map +1 -0
  151. package/dist/node-module-collector/pnpmNodeModulesCollector.js +184 -0
  152. package/dist/node-module-collector/pnpmNodeModulesCollector.js.map +1 -0
  153. package/dist/node-module-collector/traversalNodeModulesCollector.d.ts +19 -0
  154. package/dist/node-module-collector/traversalNodeModulesCollector.d.ts.map +1 -0
  155. package/dist/node-module-collector/traversalNodeModulesCollector.js +118 -0
  156. package/dist/node-module-collector/traversalNodeModulesCollector.js.map +1 -0
  157. package/dist/node-module-collector/types.d.ts +53 -0
  158. package/dist/node-module-collector/types.d.ts.map +1 -0
  159. package/dist/node-module-collector/types.js +2 -0
  160. package/dist/node-module-collector/yarnBerryNodeModulesCollector.d.ts +16 -0
  161. package/dist/node-module-collector/yarnBerryNodeModulesCollector.d.ts.map +1 -0
  162. package/dist/node-module-collector/yarnBerryNodeModulesCollector.js +87 -0
  163. package/dist/node-module-collector/yarnBerryNodeModulesCollector.js.map +1 -0
  164. package/dist/node-module-collector/yarnNodeModulesCollector.d.ts +11 -0
  165. package/dist/node-module-collector/yarnNodeModulesCollector.d.ts.map +1 -0
  166. package/dist/node-module-collector/yarnNodeModulesCollector.js +18 -0
  167. package/dist/node-module-collector/yarnNodeModulesCollector.js.map +1 -0
  168. package/dist/options/AppXOptions.d.ts +106 -0
  169. package/dist/options/AppXOptions.d.ts.map +1 -0
  170. package/dist/options/AppXOptions.js +2 -0
  171. package/dist/options/AppXOptions.js.map +1 -0
  172. package/dist/options/CommonWindowsInstallerConfiguration.d.ts +48 -0
  173. package/dist/options/CommonWindowsInstallerConfiguration.d.ts.map +1 -0
  174. package/dist/options/CommonWindowsInstallerConfiguration.js +47 -0
  175. package/dist/options/CommonWindowsInstallerConfiguration.js.map +1 -0
  176. package/dist/options/FileAssociation.d.ts +46 -0
  177. package/dist/options/FileAssociation.d.ts.map +1 -0
  178. package/dist/options/FileAssociation.js +2 -0
  179. package/dist/options/MsiOptions.d.ts +27 -0
  180. package/dist/options/MsiOptions.d.ts.map +1 -0
  181. package/dist/options/MsiOptions.js +2 -0
  182. package/dist/options/MsiOptions.js.map +1 -0
  183. package/dist/options/MsiWrappedOptions.d.ts +27 -0
  184. package/dist/options/MsiWrappedOptions.d.ts.map +1 -0
  185. package/dist/options/MsiWrappedOptions.js +2 -0
  186. package/dist/options/MsiWrappedOptions.js.map +1 -0
  187. package/dist/options/PlatformSpecificBuildOptions.d.ts +261 -0
  188. package/dist/options/PlatformSpecificBuildOptions.d.ts.map +1 -0
  189. package/dist/options/PlatformSpecificBuildOptions.js +2 -0
  190. package/dist/options/PlatformSpecificBuildOptions.js.map +1 -0
  191. package/dist/options/SnapOptions.d.ts +480 -0
  192. package/dist/options/SnapOptions.d.ts.map +1 -0
  193. package/dist/options/SnapOptions.js +2 -0
  194. package/dist/options/SnapOptions.js.map +1 -0
  195. package/dist/options/SquirrelWindowsOptions.d.ts +47 -0
  196. package/dist/options/SquirrelWindowsOptions.d.ts.map +1 -0
  197. package/dist/options/SquirrelWindowsOptions.js +2 -0
  198. package/dist/options/SquirrelWindowsOptions.js.map +1 -0
  199. package/dist/options/linuxOptions.d.ts +289 -0
  200. package/dist/options/linuxOptions.d.ts.map +1 -0
  201. package/dist/options/linuxOptions.js +2 -0
  202. package/dist/options/linuxOptions.js.map +1 -0
  203. package/dist/options/macOptions.d.ts +390 -0
  204. package/dist/options/macOptions.d.ts.map +1 -0
  205. package/dist/options/macOptions.js +2 -0
  206. package/dist/options/macOptions.js.map +1 -0
  207. package/dist/options/metadata.d.ts +54 -0
  208. package/dist/options/metadata.d.ts.map +1 -0
  209. package/dist/options/metadata.js +2 -0
  210. package/dist/options/metadata.js.map +1 -0
  211. package/dist/options/pkgOptions.d.ts +137 -0
  212. package/dist/options/pkgOptions.d.ts.map +1 -0
  213. package/dist/options/pkgOptions.js +2 -0
  214. package/dist/options/pkgOptions.js.map +1 -0
  215. package/dist/options/winOptions.d.ts +166 -0
  216. package/dist/options/winOptions.d.ts.map +1 -0
  217. package/dist/options/winOptions.js +2 -0
  218. package/dist/options/winOptions.js.map +1 -0
  219. package/dist/packager.d.ts +100 -0
  220. package/dist/packager.d.ts.map +1 -0
  221. package/dist/packager.js +491 -0
  222. package/dist/packager.js.map +1 -0
  223. package/dist/packagerApi.d.ts +32 -0
  224. package/dist/packagerApi.d.ts.map +1 -0
  225. package/dist/packagerApi.js +2 -0
  226. package/dist/packagerApi.js.map +1 -0
  227. package/dist/platformPackager.d.ts +132 -0
  228. package/dist/platformPackager.d.ts.map +1 -0
  229. package/dist/platformPackager.js +761 -0
  230. package/dist/platformPackager.js.map +1 -0
  231. package/dist/presets/rectCra.d.ts +2 -0
  232. package/dist/presets/rectCra.d.ts.map +1 -0
  233. package/dist/presets/rectCra.js +19 -0
  234. package/dist/presets/rectCra.js.map +1 -0
  235. package/dist/publish/PublishManager.d.ts +33 -0
  236. package/dist/publish/PublishManager.d.ts.map +1 -0
  237. package/dist/publish/PublishManager.js +470 -0
  238. package/dist/publish/PublishManager.js.map +1 -0
  239. package/dist/publish/updateInfoBuilder.d.ts +15 -0
  240. package/dist/publish/updateInfoBuilder.d.ts.map +1 -0
  241. package/dist/publish/updateInfoBuilder.js +221 -0
  242. package/dist/publish/updateInfoBuilder.js.map +1 -0
  243. package/dist/targets/ArchiveTarget.d.ts +12 -0
  244. package/dist/targets/ArchiveTarget.d.ts.map +1 -0
  245. package/dist/targets/ArchiveTarget.js +93 -0
  246. package/dist/targets/ArchiveTarget.js.map +1 -0
  247. package/dist/targets/archive.d.ts +27 -0
  248. package/dist/targets/archive.d.ts.map +1 -0
  249. package/dist/targets/archive.js +174 -0
  250. package/dist/targets/archive.js.map +1 -0
  251. package/dist/targets/blockmap/blockmap.d.ts +17 -0
  252. package/dist/targets/blockmap/blockmap.d.ts.map +1 -0
  253. package/dist/targets/blockmap/blockmap.js +150 -0
  254. package/dist/targets/blockmap/blockmap.js.map +1 -0
  255. package/dist/targets/differentialUpdateInfoBuilder.d.ts +16 -0
  256. package/dist/targets/differentialUpdateInfoBuilder.d.ts.map +1 -0
  257. package/dist/targets/differentialUpdateInfoBuilder.js +73 -0
  258. package/dist/targets/differentialUpdateInfoBuilder.js.map +1 -0
  259. package/dist/targets/linux/FlatpakTarget.d.ts +21 -0
  260. package/dist/targets/linux/FlatpakTarget.d.ts.map +1 -0
  261. package/dist/targets/linux/FlatpakTarget.js +156 -0
  262. package/dist/targets/linux/FlatpakTarget.js.map +1 -0
  263. package/dist/targets/linux/FpmTarget.d.ts +23 -0
  264. package/dist/targets/linux/FpmTarget.d.ts.map +1 -0
  265. package/dist/targets/linux/FpmTarget.js +365 -0
  266. package/dist/targets/linux/FpmTarget.js.map +1 -0
  267. package/dist/targets/linux/LinuxTargetHelper.d.ts +24 -0
  268. package/dist/targets/linux/LinuxTargetHelper.d.ts.map +1 -0
  269. package/dist/targets/linux/LinuxTargetHelper.js +332 -0
  270. package/dist/targets/linux/LinuxTargetHelper.js.map +1 -0
  271. package/dist/targets/linux/appimage/AppImageTarget.d.ts +16 -0
  272. package/dist/targets/linux/appimage/AppImageTarget.d.ts.map +1 -0
  273. package/dist/targets/linux/appimage/AppImageTarget.js +141 -0
  274. package/dist/targets/linux/appimage/AppImageTarget.js.map +1 -0
  275. package/dist/targets/linux/appimage/appImageUtil.d.ts +57 -0
  276. package/dist/targets/linux/appimage/appImageUtil.d.ts.map +1 -0
  277. package/dist/targets/linux/appimage/appImageUtil.js +317 -0
  278. package/dist/targets/linux/appimage/appImageUtil.js.map +1 -0
  279. package/dist/targets/linux/appimage/appLauncher.d.ts +4 -0
  280. package/dist/targets/linux/appimage/appLauncher.d.ts.map +1 -0
  281. package/dist/targets/linux/appimage/appLauncher.js +91 -0
  282. package/dist/targets/linux/appimage/appLauncher.js.map +1 -0
  283. package/dist/targets/linux/snap/SnapTarget.d.ts +37 -0
  284. package/dist/targets/linux/snap/SnapTarget.d.ts.map +1 -0
  285. package/dist/targets/linux/snap/SnapTarget.js +96 -0
  286. package/dist/targets/linux/snap/SnapTarget.js.map +1 -0
  287. package/dist/targets/linux/snap/core24.d.ts +53 -0
  288. package/dist/targets/linux/snap/core24.d.ts.map +1 -0
  289. package/dist/targets/linux/snap/core24.js +444 -0
  290. package/dist/targets/linux/snap/core24.js.map +1 -0
  291. package/dist/targets/linux/snap/coreCustom.d.ts +29 -0
  292. package/dist/targets/linux/snap/coreCustom.d.ts.map +1 -0
  293. package/dist/targets/linux/snap/coreCustom.js +60 -0
  294. package/dist/targets/linux/snap/coreCustom.js.map +1 -0
  295. package/dist/targets/linux/snap/coreLegacy.d.ts +46 -0
  296. package/dist/targets/linux/snap/coreLegacy.d.ts.map +1 -0
  297. package/dist/targets/linux/snap/coreLegacy.js +402 -0
  298. package/dist/targets/linux/snap/coreLegacy.js.map +1 -0
  299. package/dist/targets/linux/snap/snapcraftBuilder.d.ts +40 -0
  300. package/dist/targets/linux/snap/snapcraftBuilder.d.ts.map +1 -0
  301. package/dist/targets/linux/snap/snapcraftBuilder.js +414 -0
  302. package/dist/targets/linux/snap/snapcraftBuilder.js.map +1 -0
  303. package/dist/targets/mac/MacTargetHelper.d.ts +30 -0
  304. package/dist/targets/mac/MacTargetHelper.d.ts.map +1 -0
  305. package/dist/targets/mac/MacTargetHelper.js +267 -0
  306. package/dist/targets/mac/MacTargetHelper.js.map +1 -0
  307. package/dist/targets/mac/pkg.d.ts +31 -0
  308. package/dist/targets/mac/pkg.d.ts.map +1 -0
  309. package/dist/targets/mac/pkg.js +271 -0
  310. package/dist/targets/mac/pkg.js.map +1 -0
  311. package/dist/targets/targetFactory.d.ts +13 -0
  312. package/dist/targets/targetFactory.d.ts.map +1 -0
  313. package/dist/targets/targetFactory.js +94 -0
  314. package/dist/targets/targetFactory.js.map +1 -0
  315. package/dist/targets/targetUtil.d.ts +16 -0
  316. package/dist/targets/targetUtil.d.ts.map +1 -0
  317. package/dist/targets/targetUtil.js +40 -0
  318. package/dist/targets/targetUtil.js.map +1 -0
  319. package/dist/targets/win/AppxCapabilities.d.ts +9 -0
  320. package/dist/targets/win/AppxCapabilities.d.ts.map +1 -0
  321. package/dist/targets/win/AppxCapabilities.js +254 -0
  322. package/dist/targets/win/AppxCapabilities.js.map +1 -0
  323. package/dist/targets/win/AppxTarget.d.ts +18 -0
  324. package/dist/targets/win/AppxTarget.d.ts.map +1 -0
  325. package/dist/targets/win/AppxTarget.js +398 -0
  326. package/dist/targets/win/AppxTarget.js.map +1 -0
  327. package/dist/targets/win/MsiTarget.d.ts +29 -0
  328. package/dist/targets/win/MsiTarget.d.ts.map +1 -0
  329. package/dist/targets/win/MsiTarget.js +268 -0
  330. package/dist/targets/win/MsiTarget.js.map +1 -0
  331. package/dist/targets/win/MsiWrappedTarget.d.ts +20 -0
  332. package/dist/targets/win/MsiWrappedTarget.d.ts.map +1 -0
  333. package/dist/targets/win/MsiWrappedTarget.js +77 -0
  334. package/dist/targets/win/MsiWrappedTarget.js.map +1 -0
  335. package/dist/targets/win/nsis/Commands.d.ts +10 -0
  336. package/dist/targets/win/nsis/Commands.d.ts.map +1 -0
  337. package/dist/targets/win/nsis/Commands.js +2 -0
  338. package/dist/targets/win/nsis/Commands.js.map +1 -0
  339. package/dist/targets/win/nsis/Defines.d.ts +81 -0
  340. package/dist/targets/win/nsis/Defines.d.ts.map +1 -0
  341. package/dist/targets/win/nsis/Defines.js +2 -0
  342. package/dist/targets/win/nsis/Defines.js.map +1 -0
  343. package/dist/targets/win/nsis/NsisTarget.d.ts +43 -0
  344. package/dist/targets/win/nsis/NsisTarget.d.ts.map +1 -0
  345. package/dist/targets/win/nsis/NsisTarget.js +726 -0
  346. package/dist/targets/win/nsis/NsisTarget.js.map +1 -0
  347. package/dist/targets/win/nsis/WebInstallerTarget.d.ts +14 -0
  348. package/dist/targets/win/nsis/WebInstallerTarget.d.ts.map +1 -0
  349. package/dist/targets/win/nsis/WebInstallerTarget.js +43 -0
  350. package/dist/targets/win/nsis/WebInstallerTarget.js.map +1 -0
  351. package/dist/targets/win/nsis/nsisLang.d.ts +11 -0
  352. package/dist/targets/win/nsis/nsisLang.d.ts.map +1 -0
  353. package/dist/targets/win/nsis/nsisLang.js +94 -0
  354. package/dist/targets/win/nsis/nsisLang.js.map +1 -0
  355. package/dist/targets/win/nsis/nsisLicense.d.ts +5 -0
  356. package/dist/targets/win/nsis/nsisLicense.d.ts.map +1 -0
  357. package/dist/targets/win/nsis/nsisLicense.js +73 -0
  358. package/dist/targets/win/nsis/nsisLicense.js.map +1 -0
  359. package/dist/targets/win/nsis/nsisOptions.d.ts +275 -0
  360. package/dist/targets/win/nsis/nsisOptions.d.ts.map +1 -0
  361. package/dist/targets/win/nsis/nsisOptions.js +2 -0
  362. package/dist/targets/win/nsis/nsisOptions.js.map +1 -0
  363. package/dist/targets/win/nsis/nsisScriptGenerator.d.ts +13 -0
  364. package/dist/targets/win/nsis/nsisScriptGenerator.d.ts.map +1 -0
  365. package/dist/targets/win/nsis/nsisScriptGenerator.js +59 -0
  366. package/dist/targets/win/nsis/nsisScriptGenerator.js.map +1 -0
  367. package/dist/targets/win/nsis/nsisUtil.d.ts +26 -0
  368. package/dist/targets/win/nsis/nsisUtil.d.ts.map +1 -0
  369. package/dist/targets/win/nsis/nsisUtil.js +218 -0
  370. package/dist/targets/win/nsis/nsisUtil.js.map +1 -0
  371. package/dist/targets/win/nsis/nsisValidation.d.ts +19 -0
  372. package/dist/targets/win/nsis/nsisValidation.d.ts.map +1 -0
  373. package/dist/targets/win/nsis/nsisValidation.js +49 -0
  374. package/dist/targets/win/nsis/nsisValidation.js.map +1 -0
  375. package/dist/toolsets/7zip.d.ts +9 -0
  376. package/dist/toolsets/7zip.d.ts.map +1 -0
  377. package/dist/toolsets/7zip.js +80 -0
  378. package/dist/toolsets/7zip.js.map +1 -0
  379. package/dist/toolsets/appimage.d.ts +20 -0
  380. package/dist/toolsets/appimage.d.ts.map +1 -0
  381. package/dist/toolsets/appimage.js +67 -0
  382. package/dist/toolsets/appimage.js.map +1 -0
  383. package/dist/toolsets/custom.d.ts +5 -0
  384. package/dist/toolsets/custom.d.ts.map +1 -0
  385. package/dist/toolsets/custom.js +200 -0
  386. package/dist/toolsets/custom.js.map +1 -0
  387. package/dist/toolsets/fpm.d.ts +3 -0
  388. package/dist/toolsets/fpm.d.ts.map +1 -0
  389. package/dist/toolsets/fpm.js +49 -0
  390. package/dist/toolsets/fpm.js.map +1 -0
  391. package/dist/toolsets/icons.d.ts +12 -0
  392. package/dist/toolsets/icons.d.ts.map +1 -0
  393. package/dist/toolsets/icons.js +36 -0
  394. package/dist/toolsets/icons.js.map +1 -0
  395. package/dist/toolsets/linuxToolsMac.d.ts +8 -0
  396. package/dist/toolsets/linuxToolsMac.d.ts.map +1 -0
  397. package/dist/toolsets/linuxToolsMac.js +31 -0
  398. package/dist/toolsets/linuxToolsMac.js.map +1 -0
  399. package/dist/toolsets/nsis.d.ts +13 -0
  400. package/dist/toolsets/nsis.d.ts.map +1 -0
  401. package/dist/toolsets/nsis.js +100 -0
  402. package/dist/toolsets/nsis.js.map +1 -0
  403. package/dist/toolsets/winCodeSign.d.ts +42 -0
  404. package/dist/toolsets/winCodeSign.d.ts.map +1 -0
  405. package/dist/toolsets/winCodeSign.js +142 -0
  406. package/dist/toolsets/winCodeSign.js.map +1 -0
  407. package/dist/toolsets/wine.d.ts +6 -0
  408. package/dist/toolsets/wine.d.ts.map +1 -0
  409. package/dist/toolsets/wine.js +79 -0
  410. package/dist/toolsets/wine.js.map +1 -0
  411. package/dist/util/AppFileWalker.d.ts +14 -0
  412. package/dist/util/AppFileWalker.d.ts.map +1 -0
  413. package/dist/util/AppFileWalker.js +69 -0
  414. package/dist/util/AppFileWalker.js.map +1 -0
  415. package/dist/util/NodeModuleCopyHelper.d.ts +2 -0
  416. package/dist/util/NodeModuleCopyHelper.d.ts.map +1 -0
  417. package/dist/util/NodeModuleCopyHelper.js +160 -0
  418. package/dist/util/NodeModuleCopyHelper.js.map +1 -0
  419. package/dist/util/appFileCopier.d.ts +17 -0
  420. package/dist/util/appFileCopier.d.ts.map +1 -0
  421. package/dist/util/appFileCopier.js +190 -0
  422. package/dist/util/appFileCopier.js.map +1 -0
  423. package/dist/util/asyncEventEmitter.d.ts +34 -0
  424. package/dist/util/asyncEventEmitter.d.ts.map +1 -0
  425. package/dist/util/asyncEventEmitter.js +56 -0
  426. package/dist/util/asyncEventEmitter.js.map +1 -0
  427. package/dist/util/bundledTool.d.ts +8 -0
  428. package/dist/util/bundledTool.d.ts.map +1 -0
  429. package/dist/util/bundledTool.js +16 -0
  430. package/dist/util/bundledTool.js.map +1 -0
  431. package/dist/util/cacheManager.d.ts +19 -0
  432. package/dist/util/cacheManager.d.ts.map +1 -0
  433. package/dist/util/cacheManager.js +65 -0
  434. package/dist/util/cacheManager.js.map +1 -0
  435. package/dist/util/cacheState.d.ts +29 -0
  436. package/dist/util/cacheState.d.ts.map +1 -0
  437. package/dist/util/cacheState.js +134 -0
  438. package/dist/util/cacheState.js.map +1 -0
  439. package/dist/util/config/config.d.ts +13 -0
  440. package/dist/util/config/config.d.ts.map +1 -0
  441. package/dist/util/config/config.js +236 -0
  442. package/dist/util/config/config.js.map +1 -0
  443. package/dist/util/config/load.d.ts +20 -0
  444. package/dist/util/config/load.d.ts.map +1 -0
  445. package/dist/util/config/load.js +122 -0
  446. package/dist/util/config/load.js.map +1 -0
  447. package/dist/util/config/schemaValidator.d.ts +8 -0
  448. package/dist/util/config/schemaValidator.d.ts.map +1 -0
  449. package/dist/util/config/schemaValidator.js +161 -0
  450. package/dist/util/config/schemaValidator.js.map +1 -0
  451. package/dist/util/dynamicImport.d.ts +2 -0
  452. package/dist/util/dynamicImport.d.ts.map +1 -0
  453. package/dist/util/dynamicImport.js +9 -0
  454. package/dist/util/dynamicImport.js.map +1 -0
  455. package/dist/util/electronGet.d.ts +68 -0
  456. package/dist/util/electronGet.d.ts.map +1 -0
  457. package/dist/util/electronGet.js +560 -0
  458. package/dist/util/electronGet.js.map +1 -0
  459. package/dist/util/filter.d.ts +2 -0
  460. package/dist/util/filter.d.ts.map +1 -0
  461. package/dist/util/filter.js +64 -0
  462. package/dist/util/filter.js.map +1 -0
  463. package/dist/util/flags.d.ts +16 -0
  464. package/dist/util/flags.d.ts.map +1 -0
  465. package/dist/util/flags.js +53 -0
  466. package/dist/util/flags.js.map +1 -0
  467. package/dist/util/hash.d.ts +2 -0
  468. package/dist/util/hash.d.ts.map +1 -0
  469. package/dist/util/hash.js +16 -0
  470. package/dist/util/hash.js.map +1 -0
  471. package/dist/util/iconConverter.d.ts +29 -0
  472. package/dist/util/iconConverter.d.ts.map +1 -0
  473. package/dist/util/iconConverter.js +255 -0
  474. package/dist/util/iconConverter.js.map +1 -0
  475. package/dist/util/langs.d.ts +190 -0
  476. package/dist/util/langs.d.ts.map +1 -0
  477. package/dist/util/langs.js +432 -0
  478. package/dist/util/langs.js.map +1 -0
  479. package/dist/util/license.d.ts +17 -0
  480. package/dist/util/license.d.ts.map +1 -0
  481. package/dist/util/license.js +42 -0
  482. package/dist/util/license.js.map +1 -0
  483. package/dist/util/mac/macosIconComposer.d.ts +11 -0
  484. package/dist/util/mac/macosIconComposer.d.ts.map +1 -0
  485. package/dist/util/mac/macosIconComposer.js +99 -0
  486. package/dist/util/mac/macosIconComposer.js.map +1 -0
  487. package/dist/util/mac/macosVersion.d.ts +4 -0
  488. package/dist/util/mac/macosVersion.d.ts.map +1 -0
  489. package/dist/util/mac/macosVersion.js +31 -0
  490. package/dist/util/mac/macosVersion.js.map +1 -0
  491. package/dist/util/mac/plist.d.ts +8 -0
  492. package/dist/util/mac/plist.d.ts.map +1 -0
  493. package/dist/util/mac/plist.js +27 -0
  494. package/dist/util/mac/plist.js.map +1 -0
  495. package/dist/util/macroExpander.d.ts +4 -0
  496. package/dist/util/macroExpander.d.ts.map +1 -0
  497. package/dist/util/macroExpander.js +61 -0
  498. package/dist/util/macroExpander.js.map +1 -0
  499. package/dist/util/normalizePackageData.d.ts +2 -0
  500. package/dist/util/normalizePackageData.d.ts.map +1 -0
  501. package/dist/util/normalizePackageData.js +323 -0
  502. package/dist/util/normalizePackageData.js.map +1 -0
  503. package/dist/util/packageMetadata.d.ts +2 -0
  504. package/dist/util/packageMetadata.d.ts.map +1 -0
  505. package/dist/util/packageMetadata.js +118 -0
  506. package/dist/util/packageMetadata.js.map +1 -0
  507. package/dist/util/pathManager.d.ts +4 -0
  508. package/dist/util/pathManager.d.ts.map +1 -0
  509. package/dist/util/pathManager.js +17 -0
  510. package/dist/util/pathManager.js.map +1 -0
  511. package/dist/util/rebuild.d.ts +3 -0
  512. package/dist/util/rebuild.d.ts.map +1 -0
  513. package/dist/util/rebuild.js +54 -0
  514. package/dist/util/rebuild.js.map +1 -0
  515. package/dist/util/repositoryInfo.d.ts +4 -0
  516. package/dist/util/repositoryInfo.d.ts.map +1 -0
  517. package/dist/util/repositoryInfo.js +76 -0
  518. package/dist/util/repositoryInfo.js.map +1 -0
  519. package/dist/util/resolve.d.ts +3 -0
  520. package/dist/util/resolve.d.ts.map +1 -0
  521. package/dist/util/resolve.js +56 -0
  522. package/dist/util/resolve.js.map +1 -0
  523. package/dist/util/timer.d.ts +12 -0
  524. package/dist/util/timer.d.ts.map +1 -0
  525. package/dist/util/timer.js +23 -0
  526. package/dist/util/timer.js.map +1 -0
  527. package/dist/util/toolsetLock.d.ts +2 -0
  528. package/dist/util/toolsetLock.d.ts.map +1 -0
  529. package/dist/util/toolsetLock.js +20 -0
  530. package/dist/util/toolsetLock.js.map +1 -0
  531. package/dist/util/win/resEdit.d.ts +11 -0
  532. package/dist/util/win/resEdit.d.ts.map +1 -0
  533. package/dist/util/win/resEdit.js +46 -0
  534. package/dist/util/win/resEdit.js.map +1 -0
  535. package/dist/util/yarn.d.ts +23 -0
  536. package/dist/util/yarn.d.ts.map +1 -0
  537. package/dist/util/yarn.js +153 -0
  538. package/dist/util/yarn.js.map +1 -0
  539. package/dist/version.d.ts +2 -0
  540. package/dist/version.d.ts.map +1 -0
  541. package/dist/version.js +2 -0
  542. package/dist/version.js.map +1 -0
  543. package/dist/vm/MonoVm.d.ts +9 -0
  544. package/dist/vm/MonoVm.d.ts.map +1 -0
  545. package/dist/vm/MonoVm.js +16 -0
  546. package/dist/vm/MonoVm.js.map +1 -0
  547. package/dist/vm/ParallelsVm.d.ts +24 -0
  548. package/dist/vm/ParallelsVm.d.ts.map +1 -0
  549. package/dist/vm/ParallelsVm.js +107 -0
  550. package/dist/vm/ParallelsVm.js.map +1 -0
  551. package/dist/vm/PwshVm.d.ts +7 -0
  552. package/dist/vm/PwshVm.d.ts.map +1 -0
  553. package/dist/vm/PwshVm.js +21 -0
  554. package/dist/vm/PwshVm.js.map +1 -0
  555. package/dist/vm/WineVm.d.ts +14 -0
  556. package/dist/vm/WineVm.d.ts.map +1 -0
  557. package/dist/vm/WineVm.js +35 -0
  558. package/dist/vm/WineVm.js.map +1 -0
  559. package/dist/vm/vm.d.ts +15 -0
  560. package/dist/vm/vm.d.ts.map +1 -0
  561. package/dist/vm/vm.js +81 -0
  562. package/dist/vm/vm.js.map +1 -0
  563. package/dist/winPackager.d.ts +30 -0
  564. package/dist/winPackager.d.ts.map +1 -0
  565. package/dist/winPackager.js +270 -0
  566. package/dist/winPackager.js.map +1 -0
  567. package/helpers/package.json +6 -0
  568. package/helpers/remote-rebuild.js +2 -4
  569. package/package.json +30 -33
  570. package/scheme.json +379 -721
  571. package/out/Framework.d.ts +0 -36
  572. package/out/Framework.js +0 -7
  573. package/out/Framework.js.map +0 -1
  574. package/out/ProtonFramework.d.ts +0 -10
  575. package/out/ProtonFramework.js +0 -94
  576. package/out/ProtonFramework.js.map +0 -1
  577. package/out/appInfo.d.ts +0 -31
  578. package/out/appInfo.js +0 -152
  579. package/out/appInfo.js.map +0 -1
  580. package/out/asar/asar.d.ts +0 -38
  581. package/out/asar/asar.js +0 -163
  582. package/out/asar/asar.js.map +0 -1
  583. package/out/asar/asarFileChecker.d.ts +0 -2
  584. package/out/asar/asarFileChecker.js +0 -25
  585. package/out/asar/asarFileChecker.js.map +0 -1
  586. package/out/asar/asarUtil.d.ts +0 -1
  587. package/out/asar/asarUtil.js +0 -285
  588. package/out/asar/asarUtil.js.map +0 -1
  589. package/out/asar/integrity.d.ts +0 -15
  590. package/out/asar/integrity.js +0 -62
  591. package/out/asar/integrity.js.map +0 -1
  592. package/out/asar/unpackDetector.d.ts +0 -1
  593. package/out/asar/unpackDetector.js +0 -43
  594. package/out/asar/unpackDetector.js.map +0 -1
  595. package/out/binDownload.d.ts +0 -5
  596. package/out/binDownload.js +0 -104
  597. package/out/binDownload.js.map +0 -1
  598. package/out/codeSign/certInfo.d.ts +0 -54
  599. package/out/codeSign/certInfo.js +0 -466
  600. package/out/codeSign/certInfo.js.map +0 -1
  601. package/out/codeSign/codesign.d.ts +0 -3
  602. package/out/codeSign/codesign.js +0 -33
  603. package/out/codeSign/codesign.js.map +0 -1
  604. package/out/codeSign/macCodeSign.d.ts +0 -28
  605. package/out/codeSign/macCodeSign.js +0 -284
  606. package/out/codeSign/macCodeSign.js.map +0 -1
  607. package/out/codeSign/signManager.d.ts +0 -13
  608. package/out/codeSign/signManager.js +0 -3
  609. package/out/codeSign/signManager.js.map +0 -1
  610. package/out/codeSign/windowsCodeSign.d.ts +0 -7
  611. package/out/codeSign/windowsCodeSign.js +0 -38
  612. package/out/codeSign/windowsCodeSign.js.map +0 -1
  613. package/out/codeSign/windowsSignAzureManager.d.ts +0 -17
  614. package/out/codeSign/windowsSignAzureManager.js +0 -73
  615. package/out/codeSign/windowsSignAzureManager.js.map +0 -1
  616. package/out/codeSign/windowsSignToolManager.d.ts +0 -58
  617. package/out/codeSign/windowsSignToolManager.js +0 -376
  618. package/out/codeSign/windowsSignToolManager.js.map +0 -1
  619. package/out/configuration.d.ts +0 -532
  620. package/out/configuration.js +0 -3
  621. package/out/configuration.js.map +0 -1
  622. package/out/core.d.ts +0 -60
  623. package/out/core.js +0 -66
  624. package/out/core.js.map +0 -1
  625. package/out/electron/ElectronFramework.d.ts +0 -16
  626. package/out/electron/ElectronFramework.js +0 -242
  627. package/out/electron/ElectronFramework.js.map +0 -1
  628. package/out/electron/electronMac.d.ts +0 -1
  629. package/out/electron/electronMac.js +0 -262
  630. package/out/electron/electronMac.js.map +0 -1
  631. package/out/electron/electronVersion.d.ts +0 -6
  632. package/out/electron/electronVersion.js +0 -125
  633. package/out/electron/electronVersion.js.map +0 -1
  634. package/out/electron/electronWin.d.ts +0 -1
  635. package/out/electron/electronWin.js +0 -38
  636. package/out/electron/electronWin.js.map +0 -1
  637. package/out/electron/injectFFMPEG.d.ts +0 -11
  638. package/out/electron/injectFFMPEG.js +0 -57
  639. package/out/electron/injectFFMPEG.js.map +0 -1
  640. package/out/electron/search-module.d.ts +0 -23
  641. package/out/electron/search-module.js +0 -73
  642. package/out/electron/search-module.js.map +0 -1
  643. package/out/errorMessages.d.ts +0 -1
  644. package/out/errorMessages.js +0 -11
  645. package/out/errorMessages.js.map +0 -1
  646. package/out/fileMatcher.d.ts +0 -29
  647. package/out/fileMatcher.js +0 -292
  648. package/out/fileMatcher.js.map +0 -1
  649. package/out/fileTransformer.d.ts +0 -1
  650. package/out/fileTransformer.js +0 -107
  651. package/out/fileTransformer.js.map +0 -1
  652. package/out/forge-maker.d.ts +0 -5
  653. package/out/forge-maker.js +0 -23
  654. package/out/forge-maker.js.map +0 -1
  655. package/out/frameworks/LibUiFramework.d.ts +0 -47
  656. package/out/frameworks/LibUiFramework.js +0 -197
  657. package/out/frameworks/LibUiFramework.js.map +0 -1
  658. package/out/index.d.ts +0 -39
  659. package/out/index.js +0 -99
  660. package/out/index.js.map +0 -1
  661. package/out/linuxPackager.d.ts +0 -12
  662. package/out/linuxPackager.js +0 -77
  663. package/out/linuxPackager.js.map +0 -1
  664. package/out/mac/MacTargetHelper.d.ts +0 -29
  665. package/out/mac/MacTargetHelper.js +0 -273
  666. package/out/mac/MacTargetHelper.js.map +0 -1
  667. package/out/macPackager.d.ts +0 -49
  668. package/out/macPackager.js +0 -445
  669. package/out/macPackager.js.map +0 -1
  670. package/out/node-module-collector/bunNodeModulesCollector.d.ts +0 -10
  671. package/out/node-module-collector/bunNodeModulesCollector.js +0 -18
  672. package/out/node-module-collector/bunNodeModulesCollector.js.map +0 -1
  673. package/out/node-module-collector/hoist.d.ts +0 -123
  674. package/out/node-module-collector/hoist.js +0 -884
  675. package/out/node-module-collector/hoist.js.map +0 -1
  676. package/out/node-module-collector/index.d.ts +0 -18
  677. package/out/node-module-collector/index.js +0 -130
  678. package/out/node-module-collector/index.js.map +0 -1
  679. package/out/node-module-collector/moduleManager.d.ts +0 -93
  680. package/out/node-module-collector/moduleManager.js +0 -321
  681. package/out/node-module-collector/moduleManager.js.map +0 -1
  682. package/out/node-module-collector/nodeModulesCollector.d.ts +0 -137
  683. package/out/node-module-collector/nodeModulesCollector.js +0 -428
  684. package/out/node-module-collector/nodeModulesCollector.js.map +0 -1
  685. package/out/node-module-collector/npmNodeModulesCollector.d.ts +0 -14
  686. package/out/node-module-collector/npmNodeModulesCollector.js +0 -80
  687. package/out/node-module-collector/npmNodeModulesCollector.js.map +0 -1
  688. package/out/node-module-collector/packageManager.d.ts +0 -17
  689. package/out/node-module-collector/packageManager.js +0 -144
  690. package/out/node-module-collector/packageManager.js.map +0 -1
  691. package/out/node-module-collector/pnpmNodeModulesCollector.d.ts +0 -44
  692. package/out/node-module-collector/pnpmNodeModulesCollector.js +0 -191
  693. package/out/node-module-collector/pnpmNodeModulesCollector.js.map +0 -1
  694. package/out/node-module-collector/traversalNodeModulesCollector.d.ts +0 -18
  695. package/out/node-module-collector/traversalNodeModulesCollector.js +0 -122
  696. package/out/node-module-collector/traversalNodeModulesCollector.js.map +0 -1
  697. package/out/node-module-collector/types.d.ts +0 -52
  698. package/out/node-module-collector/types.js +0 -3
  699. package/out/node-module-collector/yarnBerryNodeModulesCollector.d.ts +0 -15
  700. package/out/node-module-collector/yarnBerryNodeModulesCollector.js +0 -93
  701. package/out/node-module-collector/yarnBerryNodeModulesCollector.js.map +0 -1
  702. package/out/node-module-collector/yarnNodeModulesCollector.d.ts +0 -10
  703. package/out/node-module-collector/yarnNodeModulesCollector.js +0 -22
  704. package/out/node-module-collector/yarnNodeModulesCollector.js.map +0 -1
  705. package/out/options/AppXOptions.d.ts +0 -105
  706. package/out/options/AppXOptions.js +0 -3
  707. package/out/options/AppXOptions.js.map +0 -1
  708. package/out/options/CommonWindowsInstallerConfiguration.d.ts +0 -47
  709. package/out/options/CommonWindowsInstallerConfiguration.js +0 -51
  710. package/out/options/CommonWindowsInstallerConfiguration.js.map +0 -1
  711. package/out/options/FileAssociation.d.ts +0 -45
  712. package/out/options/FileAssociation.js +0 -3
  713. package/out/options/MsiOptions.d.ts +0 -26
  714. package/out/options/MsiOptions.js +0 -3
  715. package/out/options/MsiOptions.js.map +0 -1
  716. package/out/options/MsiWrappedOptions.d.ts +0 -26
  717. package/out/options/MsiWrappedOptions.js +0 -3
  718. package/out/options/MsiWrappedOptions.js.map +0 -1
  719. package/out/options/PlatformSpecificBuildOptions.d.ts +0 -238
  720. package/out/options/PlatformSpecificBuildOptions.js +0 -3
  721. package/out/options/PlatformSpecificBuildOptions.js.map +0 -1
  722. package/out/options/SnapOptions.d.ts +0 -500
  723. package/out/options/SnapOptions.js +0 -3
  724. package/out/options/SnapOptions.js.map +0 -1
  725. package/out/options/SquirrelWindowsOptions.d.ts +0 -46
  726. package/out/options/SquirrelWindowsOptions.js +0 -3
  727. package/out/options/SquirrelWindowsOptions.js.map +0 -1
  728. package/out/options/linuxOptions.d.ts +0 -287
  729. package/out/options/linuxOptions.js +0 -3
  730. package/out/options/linuxOptions.js.map +0 -1
  731. package/out/options/macOptions.d.ts +0 -388
  732. package/out/options/macOptions.js +0 -3
  733. package/out/options/macOptions.js.map +0 -1
  734. package/out/options/metadata.d.ts +0 -53
  735. package/out/options/metadata.js +0 -3
  736. package/out/options/metadata.js.map +0 -1
  737. package/out/options/pkgOptions.d.ts +0 -136
  738. package/out/options/pkgOptions.js +0 -3
  739. package/out/options/pkgOptions.js.map +0 -1
  740. package/out/options/winOptions.d.ts +0 -164
  741. package/out/options/winOptions.js +0 -3
  742. package/out/options/winOptions.js.map +0 -1
  743. package/out/packager.d.ts +0 -99
  744. package/out/packager.js +0 -515
  745. package/out/packager.js.map +0 -1
  746. package/out/packagerApi.d.ts +0 -31
  747. package/out/packagerApi.js +0 -3
  748. package/out/packagerApi.js.map +0 -1
  749. package/out/platformPackager.d.ts +0 -101
  750. package/out/platformPackager.js +0 -714
  751. package/out/platformPackager.js.map +0 -1
  752. package/out/presets/rectCra.d.ts +0 -1
  753. package/out/presets/rectCra.js +0 -22
  754. package/out/presets/rectCra.js.map +0 -1
  755. package/out/publish/PublishManager.d.ts +0 -30
  756. package/out/publish/PublishManager.js +0 -497
  757. package/out/publish/PublishManager.js.map +0 -1
  758. package/out/publish/updateInfoBuilder.d.ts +0 -14
  759. package/out/publish/updateInfoBuilder.js +0 -226
  760. package/out/publish/updateInfoBuilder.js.map +0 -1
  761. package/out/targets/AppxCapabilities.d.ts +0 -8
  762. package/out/targets/AppxCapabilities.js +0 -258
  763. package/out/targets/AppxCapabilities.js.map +0 -1
  764. package/out/targets/AppxTarget.d.ts +0 -17
  765. package/out/targets/AppxTarget.js +0 -403
  766. package/out/targets/AppxTarget.js.map +0 -1
  767. package/out/targets/ArchiveTarget.d.ts +0 -11
  768. package/out/targets/ArchiveTarget.js +0 -88
  769. package/out/targets/ArchiveTarget.js.map +0 -1
  770. package/out/targets/FlatpakTarget.d.ts +0 -20
  771. package/out/targets/FlatpakTarget.js +0 -159
  772. package/out/targets/FlatpakTarget.js.map +0 -1
  773. package/out/targets/FpmTarget.d.ts +0 -22
  774. package/out/targets/FpmTarget.js +0 -372
  775. package/out/targets/FpmTarget.js.map +0 -1
  776. package/out/targets/LinuxTargetHelper.d.ts +0 -23
  777. package/out/targets/LinuxTargetHelper.js +0 -346
  778. package/out/targets/LinuxTargetHelper.js.map +0 -1
  779. package/out/targets/MsiTarget.d.ts +0 -28
  780. package/out/targets/MsiTarget.js +0 -268
  781. package/out/targets/MsiTarget.js.map +0 -1
  782. package/out/targets/MsiWrappedTarget.d.ts +0 -19
  783. package/out/targets/MsiWrappedTarget.js +0 -80
  784. package/out/targets/MsiWrappedTarget.js.map +0 -1
  785. package/out/targets/appimage/AppImageTarget.d.ts +0 -15
  786. package/out/targets/appimage/AppImageTarget.js +0 -147
  787. package/out/targets/appimage/AppImageTarget.js.map +0 -1
  788. package/out/targets/appimage/appImageUtil.d.ts +0 -56
  789. package/out/targets/appimage/appImageUtil.js +0 -323
  790. package/out/targets/appimage/appImageUtil.js.map +0 -1
  791. package/out/targets/appimage/appLauncher.d.ts +0 -3
  792. package/out/targets/appimage/appLauncher.js +0 -95
  793. package/out/targets/appimage/appLauncher.js.map +0 -1
  794. package/out/targets/archive.d.ts +0 -26
  795. package/out/targets/archive.js +0 -178
  796. package/out/targets/archive.js.map +0 -1
  797. package/out/targets/blockmap/blockmap.d.ts +0 -16
  798. package/out/targets/blockmap/blockmap.js +0 -153
  799. package/out/targets/blockmap/blockmap.js.map +0 -1
  800. package/out/targets/differentialUpdateInfoBuilder.d.ts +0 -15
  801. package/out/targets/differentialUpdateInfoBuilder.js +0 -80
  802. package/out/targets/differentialUpdateInfoBuilder.js.map +0 -1
  803. package/out/targets/nsis/Commands.d.ts +0 -9
  804. package/out/targets/nsis/Commands.js +0 -3
  805. package/out/targets/nsis/Commands.js.map +0 -1
  806. package/out/targets/nsis/Defines.d.ts +0 -80
  807. package/out/targets/nsis/Defines.js +0 -3
  808. package/out/targets/nsis/Defines.js.map +0 -1
  809. package/out/targets/nsis/NsisTarget.d.ts +0 -37
  810. package/out/targets/nsis/NsisTarget.js +0 -729
  811. package/out/targets/nsis/NsisTarget.js.map +0 -1
  812. package/out/targets/nsis/WebInstallerTarget.d.ts +0 -13
  813. package/out/targets/nsis/WebInstallerTarget.js +0 -47
  814. package/out/targets/nsis/WebInstallerTarget.js.map +0 -1
  815. package/out/targets/nsis/nsisLang.d.ts +0 -10
  816. package/out/targets/nsis/nsisLang.js +0 -100
  817. package/out/targets/nsis/nsisLang.js.map +0 -1
  818. package/out/targets/nsis/nsisLicense.d.ts +0 -4
  819. package/out/targets/nsis/nsisLicense.js +0 -77
  820. package/out/targets/nsis/nsisLicense.js.map +0 -1
  821. package/out/targets/nsis/nsisOptions.d.ts +0 -274
  822. package/out/targets/nsis/nsisOptions.js +0 -3
  823. package/out/targets/nsis/nsisOptions.js.map +0 -1
  824. package/out/targets/nsis/nsisScriptGenerator.d.ts +0 -12
  825. package/out/targets/nsis/nsisScriptGenerator.js +0 -64
  826. package/out/targets/nsis/nsisScriptGenerator.js.map +0 -1
  827. package/out/targets/nsis/nsisUtil.d.ts +0 -25
  828. package/out/targets/nsis/nsisUtil.js +0 -225
  829. package/out/targets/nsis/nsisUtil.js.map +0 -1
  830. package/out/targets/nsis/nsisValidation.d.ts +0 -18
  831. package/out/targets/nsis/nsisValidation.js +0 -53
  832. package/out/targets/nsis/nsisValidation.js.map +0 -1
  833. package/out/targets/pkg.d.ts +0 -30
  834. package/out/targets/pkg.js +0 -279
  835. package/out/targets/pkg.js.map +0 -1
  836. package/out/targets/snap/SnapTarget.d.ts +0 -36
  837. package/out/targets/snap/SnapTarget.js +0 -105
  838. package/out/targets/snap/SnapTarget.js.map +0 -1
  839. package/out/targets/snap/core24.d.ts +0 -52
  840. package/out/targets/snap/core24.js +0 -449
  841. package/out/targets/snap/core24.js.map +0 -1
  842. package/out/targets/snap/coreCustom.d.ts +0 -28
  843. package/out/targets/snap/coreCustom.js +0 -63
  844. package/out/targets/snap/coreCustom.js.map +0 -1
  845. package/out/targets/snap/coreLegacy.d.ts +0 -43
  846. package/out/targets/snap/coreLegacy.js +0 -416
  847. package/out/targets/snap/coreLegacy.js.map +0 -1
  848. package/out/targets/snap/snapcraftBuilder.d.ts +0 -39
  849. package/out/targets/snap/snapcraftBuilder.js +0 -419
  850. package/out/targets/snap/snapcraftBuilder.js.map +0 -1
  851. package/out/targets/targetFactory.d.ts +0 -12
  852. package/out/targets/targetFactory.js +0 -101
  853. package/out/targets/targetFactory.js.map +0 -1
  854. package/out/targets/targetUtil.d.ts +0 -14
  855. package/out/targets/targetUtil.js +0 -47
  856. package/out/targets/targetUtil.js.map +0 -1
  857. package/out/toolsets/7zip.d.ts +0 -2
  858. package/out/toolsets/7zip.js +0 -72
  859. package/out/toolsets/7zip.js.map +0 -1
  860. package/out/toolsets/icons.d.ts +0 -8
  861. package/out/toolsets/icons.js +0 -37
  862. package/out/toolsets/icons.js.map +0 -1
  863. package/out/toolsets/linux.d.ts +0 -26
  864. package/out/toolsets/linux.js +0 -146
  865. package/out/toolsets/linux.js.map +0 -1
  866. package/out/toolsets/windows.d.ts +0 -61
  867. package/out/toolsets/windows.js +0 -259
  868. package/out/toolsets/windows.js.map +0 -1
  869. package/out/toolsets/wine.d.ts +0 -5
  870. package/out/toolsets/wine.js +0 -100
  871. package/out/toolsets/wine.js.map +0 -1
  872. package/out/util/AppFileWalker.d.ts +0 -13
  873. package/out/util/AppFileWalker.js +0 -74
  874. package/out/util/AppFileWalker.js.map +0 -1
  875. package/out/util/NodeModuleCopyHelper.d.ts +0 -1
  876. package/out/util/NodeModuleCopyHelper.js +0 -165
  877. package/out/util/NodeModuleCopyHelper.js.map +0 -1
  878. package/out/util/appFileCopier.d.ts +0 -16
  879. package/out/util/appFileCopier.js +0 -251
  880. package/out/util/appFileCopier.js.map +0 -1
  881. package/out/util/asyncEventEmitter.d.ts +0 -33
  882. package/out/util/asyncEventEmitter.js +0 -63
  883. package/out/util/asyncEventEmitter.js.map +0 -1
  884. package/out/util/bundledTool.d.ts +0 -7
  885. package/out/util/bundledTool.js +0 -20
  886. package/out/util/bundledTool.js.map +0 -1
  887. package/out/util/cacheManager.d.ts +0 -18
  888. package/out/util/cacheManager.js +0 -70
  889. package/out/util/cacheManager.js.map +0 -1
  890. package/out/util/cacheState.d.ts +0 -28
  891. package/out/util/cacheState.js +0 -143
  892. package/out/util/cacheState.js.map +0 -1
  893. package/out/util/config/config.d.ts +0 -12
  894. package/out/util/config/config.js +0 -256
  895. package/out/util/config/config.js.map +0 -1
  896. package/out/util/config/load.d.ts +0 -19
  897. package/out/util/config/load.js +0 -129
  898. package/out/util/config/load.js.map +0 -1
  899. package/out/util/config/schemaValidator.d.ts +0 -7
  900. package/out/util/config/schemaValidator.js +0 -154
  901. package/out/util/config/schemaValidator.js.map +0 -1
  902. package/out/util/dynamicImport.d.ts +0 -1
  903. package/out/util/dynamicImport.js +0 -12
  904. package/out/util/dynamicImport.js.map +0 -1
  905. package/out/util/electronGet.d.ts +0 -61
  906. package/out/util/electronGet.js +0 -464
  907. package/out/util/electronGet.js.map +0 -1
  908. package/out/util/envPath.d.ts +0 -2
  909. package/out/util/envPath.js +0 -28
  910. package/out/util/envPath.js.map +0 -1
  911. package/out/util/filter.d.ts +0 -1
  912. package/out/util/filter.js +0 -68
  913. package/out/util/filter.js.map +0 -1
  914. package/out/util/flags.d.ts +0 -3
  915. package/out/util/flags.js +0 -16
  916. package/out/util/flags.js.map +0 -1
  917. package/out/util/hash.d.ts +0 -1
  918. package/out/util/hash.js +0 -19
  919. package/out/util/hash.js.map +0 -1
  920. package/out/util/iconConverter.d.ts +0 -25
  921. package/out/util/iconConverter.js +0 -260
  922. package/out/util/iconConverter.js.map +0 -1
  923. package/out/util/langs.d.ts +0 -189
  924. package/out/util/langs.js +0 -436
  925. package/out/util/langs.js.map +0 -1
  926. package/out/util/license.d.ts +0 -16
  927. package/out/util/license.js +0 -47
  928. package/out/util/license.js.map +0 -1
  929. package/out/util/macosIconComposer.d.ts +0 -10
  930. package/out/util/macosIconComposer.js +0 -102
  931. package/out/util/macosIconComposer.js.map +0 -1
  932. package/out/util/macosVersion.d.ts +0 -3
  933. package/out/util/macosVersion.js +0 -36
  934. package/out/util/macosVersion.js.map +0 -1
  935. package/out/util/macroExpander.d.ts +0 -3
  936. package/out/util/macroExpander.js +0 -64
  937. package/out/util/macroExpander.js.map +0 -1
  938. package/out/util/normalizePackageData.d.ts +0 -1
  939. package/out/util/normalizePackageData.js +0 -328
  940. package/out/util/normalizePackageData.js.map +0 -1
  941. package/out/util/packageDependencies.d.ts +0 -6
  942. package/out/util/packageDependencies.js +0 -3
  943. package/out/util/packageDependencies.js.map +0 -1
  944. package/out/util/packageMetadata.d.ts +0 -1
  945. package/out/util/packageMetadata.js +0 -124
  946. package/out/util/packageMetadata.js.map +0 -1
  947. package/out/util/pathManager.d.ts +0 -3
  948. package/out/util/pathManager.js +0 -23
  949. package/out/util/pathManager.js.map +0 -1
  950. package/out/util/plist.d.ts +0 -7
  951. package/out/util/plist.js +0 -31
  952. package/out/util/plist.js.map +0 -1
  953. package/out/util/rebuild.d.ts +0 -2
  954. package/out/util/rebuild.js +0 -60
  955. package/out/util/rebuild.js.map +0 -1
  956. package/out/util/repositoryInfo.d.ts +0 -3
  957. package/out/util/repositoryInfo.js +0 -79
  958. package/out/util/repositoryInfo.js.map +0 -1
  959. package/out/util/resEdit.d.ts +0 -10
  960. package/out/util/resEdit.js +0 -49
  961. package/out/util/resEdit.js.map +0 -1
  962. package/out/util/resolve.d.ts +0 -2
  963. package/out/util/resolve.js +0 -59
  964. package/out/util/resolve.js.map +0 -1
  965. package/out/util/timer.d.ts +0 -11
  966. package/out/util/timer.js +0 -28
  967. package/out/util/timer.js.map +0 -1
  968. package/out/util/toolsetLock.d.ts +0 -1
  969. package/out/util/toolsetLock.js +0 -23
  970. package/out/util/toolsetLock.js.map +0 -1
  971. package/out/util/yarn.d.ts +0 -22
  972. package/out/util/yarn.js +0 -160
  973. package/out/util/yarn.js.map +0 -1
  974. package/out/version.d.ts +0 -1
  975. package/out/version.js +0 -5
  976. package/out/version.js.map +0 -1
  977. package/out/vm/MonoVm.d.ts +0 -8
  978. package/out/vm/MonoVm.js +0 -20
  979. package/out/vm/MonoVm.js.map +0 -1
  980. package/out/vm/ParallelsVm.d.ts +0 -23
  981. package/out/vm/ParallelsVm.js +0 -102
  982. package/out/vm/ParallelsVm.js.map +0 -1
  983. package/out/vm/PwshVm.d.ts +0 -6
  984. package/out/vm/PwshVm.js +0 -25
  985. package/out/vm/PwshVm.js.map +0 -1
  986. package/out/vm/WineVm.d.ts +0 -12
  987. package/out/vm/WineVm.js +0 -38
  988. package/out/vm/WineVm.js.map +0 -1
  989. package/out/vm/vm.d.ts +0 -14
  990. package/out/vm/vm.js +0 -88
  991. package/out/vm/vm.js.map +0 -1
  992. package/out/winPackager.d.ts +0 -29
  993. package/out/winPackager.js +0 -271
  994. package/out/winPackager.js.map +0 -1
  995. /package/{out → dist}/node-module-collector/types.js.map +0 -0
  996. /package/{out → dist}/options/FileAssociation.js.map +0 -0
  997. /package/helpers/{dynamic-import.js → dynamic-import.cjs} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"FpmTarget.js","sourceRoot":"","sources":["../../src/targets/FpmTarget.ts"],"names":[],"mappings":";;AAAA,+CAA8J;AAC9J,+DAA0D;AAC1D,uCAAqD;AACrD,0CAA6C;AAC7C,6BAA4B;AAC5B,wCAAoC;AACpC,kCAAgC;AAChC,kDAAiD;AAIjD,8DAA4E;AAC5E,+DAAmD;AACnD,qDAAgD;AAChD,uCAAuC;AACvC,uDAAoD;AACpD,qDAAqD;AACrD,2DAAsE;AACtE,6CAAiE;AAejE,MAAqB,SAAU,SAAQ,aAAM;IAK3C,YACE,IAAY,EACK,QAAuB,EACvB,MAAyB,EACjC,MAAc;QAEvB,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;QAJD,aAAQ,GAAR,QAAQ,CAAe;QACvB,WAAM,GAAN,MAAM,CAAmB;QACjC,WAAM,GAAN,MAAM,CAAQ;QARhB,YAAO,GAA+B,IAAA,iCAAU,EAAC,EAAE,EAAE,IAAI,CAAC,QAAQ,CAAC,4BAA4B,EAAG,IAAI,CAAC,QAAQ,CAAC,MAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAA;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AAE,QAAQ,CAAC,CAAC,OAAO,CAAC,mBAAmB,EAAE,CAAC,KAAK,EAAE,EAAE,EAAE,EAAE;QACrI,kBAAG,CAAC,IAAI,CAAC,6DAA6D,CAAC,CAAA;QACvE,OAAO,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC,CAAA;IACnC,CAAC,CAAC,CAAA;IAEF,MAAM,UAAU,GAAG,MAAM,MAAM,CAAC,WAAW,CAAC,EAAE,MAAM,EAAE,IAAI,CAAC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC,EAAE,CAAC,CAAA;IAC5F,MAAM,IAAA,qBAAU,EAAC,UAAU,EAAE,MAAM,CAAC,CAAA;IACpC,OAAO,UAAU,CAAA;AACnB,CAAC","sourcesContent":["import { Arch, asArray, exec, getArchSuffix, log, serializeToYaml, stripSensitiveEnvVars, TmpDir, toLinuxArchString, unlinkIfExists, use } from \"builder-util\"\nimport { deepAssign, Nullish } from \"builder-util-runtime\"\nimport { copyFile, outputFile, stat } from \"fs-extra\"\nimport { mkdir, readFile } from \"fs/promises\"\nimport * as path from \"path\"\nimport { smarten } from \"../appInfo\"\nimport { Target } from \"../core\"\nimport * as errorMessages from \"../errorMessages\"\nimport { LinuxPackager } from \"../linuxPackager\"\nimport { DebOptions, LinuxTargetSpecificOptions } from \"../options/linuxOptions\"\nimport { ArtifactCreated } from \"../packagerApi\"\nimport { getAppUpdatePublishConfiguration } from \"../publish/PublishManager\"\nimport { objectToArgs } from \"builder-util-runtime\"\nimport { computeEnv } from \"../util/bundledTool\"\nimport { hashFile } from \"../util/hash\"\nimport { isMacOsSierra } from \"../util/macosVersion\"\nimport { getTemplatePath } from \"../util/pathManager\"\nimport { installPrefix, LinuxTargetHelper } from \"./LinuxTargetHelper\"\nimport { getFpmPath, getLinuxToolsPath } from \"../toolsets/linux\"\n\ninterface FpmOptions {\n name: string\n maintainer: string | undefined\n vendor: string\n url: string\n}\n\ninterface ScriptFiles {\n afterRemove: string\n afterInstall: string\n appArmor: string\n}\n\nexport default class FpmTarget extends Target {\n readonly options: LinuxTargetSpecificOptions = deepAssign({}, this.packager.platformSpecificBuildOptions, (this.packager.config as any)[this.name])\n\n private readonly scriptFiles: Promise<ScriptFiles>\n\n constructor(\n name: string,\n private readonly packager: LinuxPackager,\n private readonly helper: LinuxTargetHelper,\n readonly outDir: string\n ) {\n super(name, false)\n\n this.scriptFiles = this.createScripts()\n }\n\n private async createScripts(): Promise<ScriptFiles> {\n const defaultTemplatesDir = getTemplatePath(\"linux\")\n\n const packager = this.packager\n\n /** Escape a string value for safe interpolation inside a bash single-quoted\n * string (`'...'`). The only character that can break out of a POSIX\n * single-quoted context is a literal single-quote; we replace it with the\n * standard `'\\''` sequence (end quote → escaped quote → start quote).\n *\n * sanitize-filename removes characters that are illegal in filenames but\n * deliberately keeps `'` because it is valid on POSIX systems. Without\n * this extra step, an app named `O'Brien` would terminate the quoted path\n * inside the generated after-install / after-remove shell scripts, enabling\n * arbitrary command injection when the package is installed as root. */\n function bashSingleQuoteEscape(value: string): string {\n return value.replace(/'/g, \"'\\\\''\")\n }\n\n // Bash-script templates embed executable and sanitizedProductName inside\n // single-quoted shell paths — escape single quotes to prevent injection.\n const bashTemplateOptions = {\n // old API compatibility\n executable: bashSingleQuoteEscape(packager.executableName),\n sanitizedProductName: bashSingleQuoteEscape(packager.appInfo.sanitizedProductName),\n productFilename: packager.appInfo.productFilename,\n ...packager.platformSpecificBuildOptions,\n }\n\n // The AppArmor profile template uses these values inside double-quoted\n // AppArmor path patterns — no single-quote escaping needed or wanted.\n const appArmorTemplateOptions = {\n executable: packager.executableName,\n sanitizedProductName: packager.appInfo.sanitizedProductName,\n productFilename: packager.appInfo.productFilename,\n ...packager.platformSpecificBuildOptions,\n }\n\n function getResource(value: string | Nullish, defaultFile: string) {\n if (value == null) {\n return path.join(defaultTemplatesDir, defaultFile)\n }\n return path.resolve(packager.projectDir, value)\n }\n\n return {\n afterInstall: await writeConfigFile(packager.info.tempDirManager, getResource(this.options.afterInstall, \"after-install.tpl\"), bashTemplateOptions),\n afterRemove: await writeConfigFile(packager.info.tempDirManager, getResource(this.options.afterRemove, \"after-remove.tpl\"), bashTemplateOptions),\n appArmor: await writeConfigFile(packager.info.tempDirManager, getResource(this.options.appArmorProfile, \"apparmor-profile.tpl\"), appArmorTemplateOptions),\n }\n }\n\n checkOptions(): Promise<any> {\n return this.computeFpmMetaInfoOptions()\n }\n\n private async computeFpmMetaInfoOptions(): Promise<FpmOptions> {\n const packager = this.packager\n const projectUrl = await packager.appInfo.computePackageUrl()\n const errors: Array<string> = []\n if (projectUrl == null) {\n errors.push(\"Please specify project homepage, see https://www.electron.build/configuration#metadata\")\n }\n\n const options = this.options\n let author = options.maintainer\n if (author == null) {\n const a = packager.info.metadata.author\n if (a == null || a.email == null) {\n errors.push(errorMessages.authorEmailIsMissed)\n } else {\n author = `${a.name} <${a.email}>`\n }\n }\n\n if (errors.length > 0) {\n throw new Error(errors.join(\"\\n\\n\"))\n }\n\n return {\n name: options.packageName ?? this.packager.appInfo.linuxPackageName,\n maintainer: author!,\n url: projectUrl!,\n vendor: options.vendor || author!,\n }\n }\n\n async build(appOutDir: string, arch: Arch): Promise<any> {\n const target = this.name\n\n // tslint:disable:no-invalid-template-strings\n let nameFormat = \"${name}-${version}-${arch}.${ext}\"\n let isUseArchIfX64 = false\n if (target === \"deb\") {\n nameFormat = \"${name}_${version}_${arch}.${ext}\"\n isUseArchIfX64 = true\n } else if (target === \"rpm\") {\n nameFormat = \"${name}-${version}.${arch}.${ext}\"\n isUseArchIfX64 = true\n }\n\n const packager = this.packager\n const artifactName = packager.expandArtifactNamePattern(this.options, target, arch, nameFormat, !isUseArchIfX64)\n const artifactPath = path.join(this.outDir, artifactName)\n\n await packager.info.emitArtifactBuildStarted({\n targetPresentableName: target,\n file: artifactPath,\n arch,\n })\n\n await unlinkIfExists(artifactPath)\n if (packager.packagerOptions.prepackaged != null) {\n await mkdir(this.outDir, { recursive: true })\n }\n const linuxDistType = packager.packagerOptions.prepackaged || path.join(this.outDir, `linux${getArchSuffix(arch)}-unpacked`)\n const resourceDir = packager.getResourcesDir(linuxDistType)\n\n const publishConfig = this.supportsAutoUpdate(target)\n ? await getAppUpdatePublishConfiguration(packager, this.options, arch, false /* in any case validation will be done on publish step */)\n : null\n if (publishConfig != null) {\n log.info({ resourceDir: log.filePath(resourceDir) }, `adding autoupdate files for: ${target}`)\n await outputFile(path.join(resourceDir, \"app-update.yml\"), serializeToYaml(publishConfig))\n // Extra file needed for auto-updater to detect installation method\n await outputFile(path.join(resourceDir, \"package-type\"), target)\n }\n\n const scripts = await this.scriptFiles\n\n // Install AppArmor support for ubuntu 24+\n // https://github.com/electron-userland/electron-builder/issues/8635\n await copyFile(scripts.appArmor, path.join(resourceDir, \"apparmor-profile\"))\n\n const appInfo = packager.appInfo\n const options = this.options\n const synopsis = options.synopsis\n const args = [\n \"--architecture\",\n toLinuxArchString(arch, target),\n \"--after-install\",\n scripts.afterInstall,\n \"--after-remove\",\n scripts.afterRemove,\n \"--description\",\n smarten(target === \"rpm\" ? this.helper.getDescription(options) : `${synopsis || \"\"}\\n ${this.helper.getDescription(options)}`),\n \"--version\",\n this.helper.getSanitizedVersion(target),\n \"--package\",\n artifactPath,\n ]\n\n const meta = await this.computeFpmMetaInfoOptions()\n args.push(...objectToArgs({ name: meta.name, maintainer: meta.maintainer ?? null, vendor: meta.vendor, url: meta.url }))\n\n const packageCategory = options.packageCategory\n if (packageCategory != null) {\n args.push(\"--category\", packageCategory)\n }\n\n if (target === \"deb\") {\n args.push(\"--deb-priority\", (options as DebOptions).priority ?? \"optional\")\n } else if (target === \"rpm\") {\n if (synopsis != null) {\n args.push(\"--rpm-summary\", smarten(synopsis))\n }\n }\n\n const fpmConfiguration: FpmConfiguration = {\n args,\n target,\n }\n\n if (options.compression != null) {\n fpmConfiguration.compression = options.compression\n }\n\n // noinspection JSDeprecatedSymbols\n const depends = options.depends\n if (depends != null) {\n if (Array.isArray(depends)) {\n fpmConfiguration.customDepends = depends\n } else if (typeof depends === \"string\") {\n fpmConfiguration.customDepends = [depends as string]\n } else {\n throw new Error(`depends must be Array or String, but specified as: ${depends}`)\n }\n } else {\n fpmConfiguration.customDepends = this.getDefaultDepends(target)\n }\n\n if (target === \"deb\") {\n const recommends = (options as DebOptions).recommends\n if (recommends) {\n fpmConfiguration.customRecommends = asArray(recommends)\n } else {\n fpmConfiguration.customRecommends = this.getDefaultRecommends(target)\n }\n }\n\n use(packager.info.metadata.license, it => args.push(\"--license\", it))\n use(appInfo.buildNumber, it =>\n args.push(\n \"--iteration\",\n // dashes are not supported for iteration in older versions of fpm\n // https://github.com/jordansissel/fpm/issues/1833\n it.split(\"-\").join(\"_\")\n )\n )\n\n use(options.fpm, it => args.push(...it))\n\n args.push(`${appOutDir}/=${installPrefix}/${appInfo.sanitizedProductName}`)\n for (const icon of await this.helper.icons) {\n const extWithDot = path.extname(icon.file)\n const sizeName = extWithDot === \".svg\" ? \"scalable\" : `${icon.size}x${icon.size}`\n args.push(`${icon.file}=/usr/share/icons/hicolor/${sizeName}/apps/${packager.executableName}${extWithDot}`)\n }\n\n const mimeTypeFilePath = await this.helper.mimeTypeFiles\n if (mimeTypeFilePath != null) {\n args.push(`${mimeTypeFilePath}=/usr/share/mime/packages/${packager.executableName}.xml`)\n }\n\n const desktopFilePath = await this.helper.writeDesktopEntry(this.options)\n args.push(`${desktopFilePath}=/usr/share/applications/${this.helper.getDesktopFileName()}.desktop`)\n\n if (packager.packagerOptions.effectiveOptionComputed != null && (await packager.packagerOptions.effectiveOptionComputed([args, desktopFilePath]))) {\n return\n }\n\n const env = {\n ...stripSensitiveEnvVars(process.env),\n }\n\n // rpmbuild wants directory rpm with some default config files. Even if we can use dylibbundler, path to such config files are not changed (we need to replace in the binary)\n // so, for now, brew install rpm is still required.\n if (target !== \"rpm\" && (await isMacOsSierra())) {\n const linuxToolsPath = await getLinuxToolsPath()\n Object.assign(env, {\n PATH: computeEnv(process.env.PATH, [path.join(linuxToolsPath, \"bin\")]),\n DYLD_LIBRARY_PATH: computeEnv(process.env.DYLD_LIBRARY_PATH, [path.join(linuxToolsPath, \"lib\")]),\n })\n }\n\n await this.executeFpm(target, fpmConfiguration, env)\n\n let info: ArtifactCreated = {\n file: artifactPath,\n target: this,\n arch,\n packager,\n }\n if (publishConfig != null) {\n info = {\n ...info,\n safeArtifactName: packager.computeSafeArtifactName(artifactName, target, arch, !isUseArchIfX64),\n isWriteUpdateInfo: true,\n updateInfo: {\n sha512: await hashFile(artifactPath),\n size: (await stat(artifactPath)).size,\n },\n }\n }\n await packager.info.emitArtifactBuildCompleted(info)\n }\n\n private async executeFpm(target: string, fpmConfiguration: FpmConfiguration, env: any) {\n const fpmArgs = [\"-s\", \"dir\", \"--force\", \"-t\", target]\n const forceDebugLogging = process.env.FPM_DEBUG === \"true\"\n if (forceDebugLogging) {\n fpmArgs.push(\"--debug\")\n }\n if (log.isDebugEnabled) {\n fpmArgs.push(\"--log\", \"debug\")\n }\n fpmConfiguration.customDepends?.forEach(it => fpmArgs.push(\"-d\", it))\n if (target === \"deb\") {\n fpmConfiguration.customRecommends?.forEach(it => fpmArgs.push(\"--deb-recommends\", it))\n }\n\n const defaultCompression = target === \"rpm\" ? \"xzmt\" : \"xz\"\n fpmArgs.push(...this.configureTargetSpecificOptions(target, fpmConfiguration.compression ?? defaultCompression))\n fpmArgs.push(...fpmConfiguration.args)\n\n const fpmPath = await getFpmPath()\n\n await exec(fpmPath, fpmArgs, { env }).catch(e => {\n if (e.message.includes(\"Need executable 'rpmbuild' to convert dir to rpm\")) {\n const hint = \"to build rpm, executable rpmbuild is required, please install rpm package on your system. \"\n if (process.platform === \"darwin\") {\n log.error(null, hint + \"(brew install rpm)\")\n } else {\n log.error(null, hint + \"(sudo apt-get install rpm)\")\n }\n }\n if (e.message.includes(\"xz: not found\")) {\n const hint = \"to build rpm, executable xz is required, please install xz package on your system. \"\n if (process.platform === \"darwin\") {\n log.error(null, hint + \"(brew install xz)\")\n } else {\n log.error(null, hint + \"(sudo apt-get install xz-utils)\")\n }\n }\n if (e.message.includes(\"error: File not found\")) {\n log.error(\n { fpmArgs, ...fpmConfiguration },\n \"fpm failed to find the specified files. Please check your configuration and ensure all paths are correct. To see what files triggered this, set the environment variable FPM_DEBUG=true\"\n )\n if (forceDebugLogging) {\n log.error(null, e.message)\n }\n throw new Error(`FPM failed to find the specified files. Please check your configuration and ensure all paths are correct. Command: ${fpmPath} ${fpmArgs.join(\" \")}`)\n }\n throw e\n })\n }\n\n private supportsAutoUpdate(target: string) {\n return [\"deb\", \"rpm\", \"pacman\"].includes(target)\n }\n\n private getDefaultDepends(target: string): string[] {\n switch (target) {\n case \"deb\":\n return [\"libgtk-3-0\", \"libnotify4\", \"libnss3\", \"libxss1\", \"libxtst6\", \"xdg-utils\", \"libatspi2.0-0\", \"libuuid1\", \"libsecret-1-0\"]\n\n case \"rpm\":\n return [\n \"gtk3\" /* for electron 2+ (electron 1 uses gtk2, but this old version is not supported anymore) */,\n \"libnotify\",\n \"nss\",\n \"libXScrnSaver\",\n \"(libXtst or libXtst6)\",\n \"xdg-utils\",\n \"at-spi2-core\" /* since 5.0.0 */,\n \"(libuuid or libuuid1)\" /* since 4.0.0 */,\n ]\n\n case \"pacman\":\n return [\"c-ares\", \"ffmpeg\", \"gtk3\", \"http-parser\", \"libevent\", \"libvpx\", \"libxslt\", \"libxss\", \"minizip\", \"nss\", \"re2\", \"snappy\", \"libnotify\", \"libappindicator-gtk3\"]\n\n default:\n return []\n }\n }\n\n private getDefaultRecommends(target: string): string[] {\n switch (target) {\n case \"deb\":\n return [\"libappindicator3-1\"]\n default:\n return []\n }\n }\n\n private configureTargetSpecificOptions(target: string, compression: string): string[] {\n switch (target) {\n case \"rpm\":\n return [\"--rpm-os\", \"linux\", \"--rpm-compression\", compression === \"xz\" ? \"xzmt\" : compression]\n case \"deb\":\n return [\"--deb-compression\", compression]\n case \"pacman\":\n return [\"--pacman-compression\", compression]\n }\n return []\n }\n}\n\ninterface FpmConfiguration {\n target: string\n args: Array<string>\n customDepends?: Array<string>\n customRecommends?: Array<string>\n compression?: LinuxTargetSpecificOptions[\"compression\"]\n}\n\nasync function writeConfigFile(tmpDir: TmpDir, templatePath: string, options: any): Promise<string> {\n //noinspection JSUnusedLocalSymbols\n function replacer(match: string, p1: string) {\n if (p1 in options) {\n return options[p1]\n } else {\n throw new Error(`Macro ${p1} is not defined`)\n }\n }\n const config = (await readFile(templatePath, \"utf8\")).replace(/\\${([a-zA-Z]+)}/g, replacer).replace(/<%=([a-zA-Z]+)%>/g, (match, p1) => {\n log.warn(\"<%= varName %> is deprecated, please use ${varName} instead\")\n return replacer(match, p1.trim())\n })\n\n const outputPath = await tmpDir.getTempFile({ suffix: path.basename(templatePath, \".tpl\") })\n await outputFile(outputPath, config)\n return outputPath\n}\n"]}
@@ -1,23 +0,0 @@
1
- import { LinuxPackager } from "../linuxPackager";
2
- import { CommonLinuxOptions } from "../options/linuxOptions";
3
- import { SnapCore } from "./snap/SnapTarget";
4
- import { IconInfo } from "../util/iconConverter";
5
- export declare const installPrefix = "/opt";
6
- export declare class LinuxTargetHelper {
7
- private packager;
8
- private readonly iconPromise;
9
- private readonly mimeTypeFilesPromise;
10
- maxIconPath: string | null;
11
- constructor(packager: LinuxPackager);
12
- get icons(): Promise<Array<IconInfo>>;
13
- get mimeTypeFiles(): Promise<string | null>;
14
- getSnapCore(): SnapCore<any>;
15
- isElectronVersionGreaterOrEqualThan(version: string, fallback?: string): boolean;
16
- private computeMimeTypeFiles;
17
- private computeDesktopIcons;
18
- getDescription(options: CommonLinuxOptions): string;
19
- getSanitizedVersion(target: string): string;
20
- writeDesktopEntry(targetSpecificOptions: CommonLinuxOptions, exec?: string, destination?: string | null, extra?: Record<string, string>): Promise<string>;
21
- getDesktopFileName(fallback?: string): string;
22
- computeDesktopEntry(targetSpecificOptions: CommonLinuxOptions, exec?: string, extra?: Record<string, string>): Promise<string>;
23
- }
@@ -1,346 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LinuxTargetHelper = exports.installPrefix = void 0;
4
- const builder_util_1 = require("builder-util");
5
- const builder_util_runtime_1 = require("builder-util-runtime");
6
- const fs_extra_1 = require("fs-extra");
7
- const lazy_val_1 = require("lazy-val");
8
- const path_1 = require("path");
9
- const semver = require("semver");
10
- const core24_1 = require("./snap/core24");
11
- const coreCustom_1 = require("./snap/coreCustom");
12
- const coreLegacy_1 = require("./snap/coreLegacy");
13
- /**
14
- * Escape a string value for use in a freedesktop .desktop file string field
15
- * (Name, Comment, StartupWMClass, etc.).
16
- *
17
- * The freedesktop Desktop Entry Specification requires that the following
18
- * characters be escaped in string / localestring values:
19
- * \n → \\n (newline — would inject new key=value lines otherwise)
20
- * \r → \\r
21
- * \t → \\t
22
- * \\ → \\\\
23
- *
24
- * Without escaping, a productName or description containing a literal newline
25
- * can inject arbitrary key=value pairs into the generated .desktop file,
26
- * potentially overriding the Exec key.
27
- *
28
- * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#value-types
29
- */
30
- function desktopStringEscape(value) {
31
- return value.replace(/\\/g, "\\\\").replace(/\n/g, "\\n").replace(/\r/g, "\\r").replace(/\t/g, "\\t");
32
- }
33
- /**
34
- * Characters that require an Exec argument to be double-quoted per the
35
- * freedesktop Desktop Entry Specification. Plain alphanumeric args and
36
- * field codes must NOT be wrapped in quotes.
37
- *
38
- * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables
39
- */
40
- const EXEC_RESERVED_RE = /[\s"'`\\<>~|&;$*?#()]/;
41
- /**
42
- * Quote a single argument for use in a .desktop file Exec key.
43
- *
44
- * Field codes (`%f`, `%u`, `%F`, `%U`, etc.) MUST be left unquoted — the
45
- * desktop launcher only expands them in unquoted token positions. Wrapping
46
- * them in `"…"` causes the launcher to treat them as literal strings, which
47
- * breaks file-association / drag-and-drop functionality.
48
- *
49
- * For all other arguments, double-quoting is used when the argument contains
50
- * any character that would be misinterpreted by the launcher without quoting
51
- * (spaces, shell metacharacters, etc.). Safe plain-word args are passed
52
- * through unchanged to keep the Exec line readable.
53
- *
54
- * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables
55
- */
56
- function desktopExecArgEscape(arg) {
57
- // Field codes (%f, %u, %F, %U, %i, %c, %k, …) must never be quoted.
58
- if (/^%[a-zA-Z]$/.test(arg)) {
59
- return arg;
60
- }
61
- // Only quote when the arg actually contains characters that need it.
62
- if (EXEC_RESERVED_RE.test(arg)) {
63
- return `"${arg.replace(/\\/g, "\\\\").replace(/"/g, '\\"')}"`;
64
- }
65
- return arg;
66
- }
67
- function mapLinuxCompressionToSnap(level) {
68
- if (level === "store") {
69
- return "lzo";
70
- }
71
- if (level === "maximum") {
72
- return "xz";
73
- }
74
- return undefined;
75
- }
76
- exports.installPrefix = "/opt";
77
- class LinuxTargetHelper {
78
- constructor(packager) {
79
- this.packager = packager;
80
- this.iconPromise = new lazy_val_1.Lazy(() => this.computeDesktopIcons());
81
- this.mimeTypeFilesPromise = new lazy_val_1.Lazy(() => this.computeMimeTypeFiles());
82
- this.maxIconPath = null;
83
- }
84
- get icons() {
85
- return this.iconPromise.value;
86
- }
87
- get mimeTypeFiles() {
88
- return this.mimeTypeFilesPromise.value;
89
- }
90
- getSnapCore() {
91
- const { snapcraft, snap: legacySnap } = this.packager.config;
92
- if (snapcraft != null && legacySnap != null) {
93
- builder_util_1.log.warn("Both `snapcraft` and `snap` configurations are present. `snapcraft` takes precedence; please remove the `snap` key to silence this warning.");
94
- }
95
- // Merge linux-level options (category, description, mimeTypes, etc.) as the base so they
96
- // propagate into the generated snapcraft.yaml and .desktop file without requiring users to
97
- // duplicate them under core24/core18/etc. Per-core options always win for conflicts.
98
- // linux.compression is a CompressionLevel ("store"/"normal"/"maximum"); snap compression is an
99
- // algorithm ("xz"/"lzo"). Map the level to the nearest algorithm; per-core options override.
100
- const { compression: linuxCompression, ...linuxOptions } = this.packager.platformSpecificBuildOptions;
101
- const snapLinuxOptions = { ...linuxOptions, compression: mapLinuxCompressionToSnap(linuxCompression) };
102
- if (snapcraft != null) {
103
- const core = snapcraft.base;
104
- const options = snapcraft[core] || {};
105
- switch (core) {
106
- case "core18":
107
- case "core20":
108
- case "core22":
109
- if (!this.isElectronVersionGreaterOrEqualThan("4.0.0")) {
110
- if (!this.isElectronVersionGreaterOrEqualThan("2.0.0-beta.1")) {
111
- throw new builder_util_1.InvalidConfigurationError("Electron 2 and higher is required to build Snap with core18/core20/core22");
112
- }
113
- builder_util_1.log.warn(null, "electron 4 and higher is highly recommended for Snap with core18/core20/core22");
114
- }
115
- return new coreLegacy_1.SnapCoreLegacy(this.packager, this, (0, builder_util_runtime_1.deepAssign)({}, snapLinuxOptions, { base: core, ...options }));
116
- case "core24":
117
- if (!this.isElectronVersionGreaterOrEqualThan("28.0.0")) {
118
- if (!this.isElectronVersionGreaterOrEqualThan("25.0.0")) {
119
- throw new builder_util_1.InvalidConfigurationError("Electron 25 and higher is required to build Snap with core24");
120
- }
121
- builder_util_1.log.warn(null, "electron 28 and higher is highly recommended for Snap with core24");
122
- }
123
- return new core24_1.SnapCore24(this.packager, this, (0, builder_util_runtime_1.deepAssign)({}, snapLinuxOptions, options));
124
- case "custom":
125
- // Pass-through: do not inject linux options into user-supplied yaml
126
- return new coreCustom_1.SnapCoreCustom(this.packager, this, snapcraft.custom || {});
127
- }
128
- }
129
- if (legacySnap != null) {
130
- builder_util_1.log.warn({
131
- reason: "`snap` configuration is deprecated",
132
- docs: "https://www.electron.build/snapcraft",
133
- }, "please consider migrating `snap` configuration to `snapcraft.<core>` and remove `snap` configuration");
134
- }
135
- return new coreLegacy_1.SnapCoreLegacy(this.packager, this, (0, builder_util_runtime_1.deepAssign)({}, snapLinuxOptions, legacySnap !== null && legacySnap !== void 0 ? legacySnap : {}));
136
- }
137
- isElectronVersionGreaterOrEqualThan(version, fallback) {
138
- const electronVersion = this.packager.config.electronVersion;
139
- if (!electronVersion) {
140
- return fallback ? semver.gte(fallback, version) : true;
141
- }
142
- return semver.gte(electronVersion, version);
143
- }
144
- async computeMimeTypeFiles() {
145
- const items = [];
146
- for (const fileAssociation of this.packager.fileAssociations) {
147
- if (!fileAssociation.mimeType) {
148
- continue;
149
- }
150
- const data = `<mime-type type="${fileAssociation.mimeType}">
151
- <glob pattern="*.${fileAssociation.ext}"/>
152
- ${fileAssociation.description ? `<comment>${fileAssociation.description}</comment>` : ""}
153
- <icon name="x-office-document" />
154
- </mime-type>`;
155
- items.push(data);
156
- }
157
- if (items.length === 0) {
158
- return null;
159
- }
160
- const file = await this.packager.getTempFile(".xml");
161
- await (0, fs_extra_1.outputFile)(file, '<?xml version="1.0" encoding="utf-8"?>\n<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">\n' + items.join("\n") + "\n</mime-info>");
162
- return file;
163
- }
164
- // must be name without spaces and other special characters, but not product name used
165
- async computeDesktopIcons() {
166
- var _a, _b, _c;
167
- const packager = this.packager;
168
- const { platformSpecificBuildOptions, config } = packager;
169
- const sources = [platformSpecificBuildOptions.icon, (_b = (_a = config.mac) === null || _a === void 0 ? void 0 : _a.icon) !== null && _b !== void 0 ? _b : config.icon].filter(str => !!str);
170
- // If no explicit sources are defined, fallback to buildResources directory, then default framework icon
171
- let fallbackSources = [...(0, builder_util_1.asArray)(packager.getDefaultFrameworkIcon())];
172
- const buildResources = (_c = config.directories) === null || _c === void 0 ? void 0 : _c.buildResources;
173
- if (buildResources && (await (0, builder_util_1.exists)((0, path_1.join)(buildResources, "icons")))) {
174
- fallbackSources = [buildResources, ...fallbackSources];
175
- }
176
- // need to put here and not as default because need to resolve image size
177
- const result = await packager.resolveIcon(sources, fallbackSources, "set");
178
- this.maxIconPath = result[result.length - 1].file;
179
- // Ignore .icon files for linux (they are exclusive for macOS)
180
- return result.filter(icon => !icon.file.endsWith(".icon"));
181
- }
182
- getDescription(options) {
183
- return options.description || this.packager.appInfo.description;
184
- }
185
- getSanitizedVersion(target) {
186
- const { appInfo: { version }, } = this.packager;
187
- switch (target) {
188
- case "pacman":
189
- return version.replace(/-/g, "_");
190
- case "rpm":
191
- case "deb":
192
- return version.replace(/-/g, "~");
193
- default:
194
- return version;
195
- }
196
- }
197
- async writeDesktopEntry(targetSpecificOptions, exec, destination, extra) {
198
- const data = await this.computeDesktopEntry(targetSpecificOptions, exec, extra);
199
- const file = destination || (await this.packager.getTempFile(`${this.packager.appInfo.productFilename}.desktop`));
200
- await (0, fs_extra_1.outputFile)(file, data);
201
- return file;
202
- }
203
- getDesktopFileName(fallback = this.packager.executableName) {
204
- var _a;
205
- if (!this.packager.platformSpecificBuildOptions.syncDesktopName) {
206
- return fallback;
207
- }
208
- const trimmedDesktopName = (_a = this.packager.info.metadata.desktopName) === null || _a === void 0 ? void 0 : _a.trim();
209
- if ((0, builder_util_1.isEmptyOrSpaces)(trimmedDesktopName)) {
210
- return fallback;
211
- }
212
- const basename = trimmedDesktopName.replace(/\.desktop$/, "");
213
- // Guard against path traversal: desktopName flows into filesystem paths
214
- // (snap/gui/<name>.desktop, /usr/share/applications/<name>.desktop, etc.).
215
- if (/[/\\]/.test(basename) || [...basename].some(c => c.charCodeAt(0) === 0)) {
216
- throw new builder_util_1.InvalidConfigurationError(`desktopName "${trimmedDesktopName}" produces an invalid .desktop filename — remove any path separators or NUL characters`);
217
- }
218
- return basename;
219
- }
220
- computeDesktopEntry(targetSpecificOptions, exec, extra) {
221
- var _a, _b, _c, _d, _e, _f, _g;
222
- if (exec != null && exec.length === 0) {
223
- throw new Error("Specified exec is empty");
224
- }
225
- // https://github.com/electron-userland/electron-builder/issues/3418
226
- if ((_b = (_a = targetSpecificOptions.desktop) === null || _a === void 0 ? void 0 : _a.entry) === null || _b === void 0 ? void 0 : _b.Exec) {
227
- throw new Error("Please specify executable name as linux.executableName instead of linux.desktop.Exec");
228
- }
229
- const packager = this.packager;
230
- const appInfo = packager.appInfo;
231
- const executableArgs = targetSpecificOptions.executableArgs;
232
- if (exec == null) {
233
- exec = `${exports.installPrefix}/${appInfo.sanitizedProductName}/${packager.executableName}`;
234
- if (!/^[/0-9A-Za-z._-]+$/.test(exec)) {
235
- exec = `"${exec}"`;
236
- }
237
- if (executableArgs) {
238
- exec += " ";
239
- // Each arg is double-quoted per the freedesktop Exec key spec so that
240
- // spaces, $, ;, & and other reserved characters are not misinterpreted.
241
- exec += executableArgs.map(desktopExecArgEscape).join(" ");
242
- }
243
- // https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables
244
- const execCodes = ["%f", "%u", "%F", "%U"];
245
- if (executableArgs == null || executableArgs.findIndex(arg => execCodes.includes(arg)) === -1) {
246
- exec += " %U";
247
- }
248
- }
249
- // https://github.com/electron-userland/electron-builder/issues/9103
250
- // Electron derives app_id from desktopName in package.json; StartupWMClass must match.
251
- // https://github.com/electron/electron/blob/9a7b73b5334f1d72c08e2d5e94106706ed751186/lib/browser/init.ts#L128-L133
252
- const trimmedDesktopName = (_c = packager.info.metadata.desktopName) === null || _c === void 0 ? void 0 : _c.trim();
253
- if ((0, builder_util_1.isEmptyOrSpaces)(trimmedDesktopName)) {
254
- builder_util_1.log.warn({
255
- reason: "desktopName is not set in package.json",
256
- docs: "https://www.electron.build/linux#window-association-desktopname--syncdesktopname",
257
- }, "electron uses desktopName as app_id / WM_CLASS for window association. Without it desktop environments may not link running windows to this .desktop entry. Set desktopName in package.json and linux.syncDesktopName: true to fix.");
258
- }
259
- const wmClass = !(0, builder_util_1.isEmptyOrSpaces)(trimmedDesktopName) ? trimmedDesktopName.replace(/\.desktop$/, "") : appInfo.productName;
260
- const desktopMeta = (0, builder_util_runtime_1.deepAssign)({
261
- // String values are escaped per the freedesktop spec (\\, \n, \r, \t)
262
- // so that a product name containing a newline cannot inject new key=value
263
- // pairs into the .desktop file (e.g. overriding the Exec key).
264
- Name: desktopStringEscape(appInfo.productName),
265
- Exec: exec,
266
- Terminal: "false",
267
- Type: "Application",
268
- Icon: packager.executableName,
269
- // https://askubuntu.com/questions/367396/what-represent-the-startupwmclass-field-of-a-desktop-file
270
- // Set to desktopName (minus .desktop suffix) when provided, so it matches Electron's
271
- // app_id and desktop environments can associate running windows with this entry.
272
- // Falls back to productName for apps that don't set desktopName.
273
- // to get WM_CLASS of running window: xprop WM_CLASS
274
- // StartupWMClass doesn't work for unicode
275
- // https://github.com/electron/electron/blob/2-0-x/atom/browser/native_window_views.cc#L226
276
- StartupWMClass: desktopStringEscape(wmClass),
277
- }, extra, (_e = (_d = targetSpecificOptions.desktop) === null || _d === void 0 ? void 0 : _d.entry) !== null && _e !== void 0 ? _e : {});
278
- const description = this.getDescription(targetSpecificOptions);
279
- if (!(0, builder_util_1.isEmptyOrSpaces)(description)) {
280
- desktopMeta.Comment = desktopStringEscape(description);
281
- }
282
- const mimeTypes = (0, builder_util_1.asArray)(targetSpecificOptions.mimeTypes);
283
- for (const fileAssociation of packager.fileAssociations) {
284
- if (fileAssociation.mimeType != null) {
285
- mimeTypes.push(fileAssociation.mimeType);
286
- }
287
- }
288
- for (const protocol of (0, builder_util_1.asArray)(packager.config.protocols).concat((0, builder_util_1.asArray)(packager.platformSpecificBuildOptions.protocols))) {
289
- for (const scheme of (0, builder_util_1.asArray)(protocol.schemes)) {
290
- mimeTypes.push(`x-scheme-handler/${scheme}`);
291
- }
292
- }
293
- if (mimeTypes.length !== 0) {
294
- desktopMeta.MimeType = mimeTypes.join(";") + ";";
295
- }
296
- let category = targetSpecificOptions.category;
297
- if ((0, builder_util_1.isEmptyOrSpaces)(category)) {
298
- const macCategory = (packager.config.mac || {}).category;
299
- if (macCategory != null) {
300
- category = macToLinuxCategory[macCategory];
301
- }
302
- if (category == null) {
303
- // https://github.com/develar/onshape-desktop-shell/issues/48
304
- if (macCategory != null) {
305
- builder_util_1.log.warn({ macCategory }, "cannot map macOS category to Linux. If possible mapping is known for you, please file issue to add it.");
306
- }
307
- builder_util_1.log.warn({
308
- reason: "linux.category is not set and cannot map from macOS",
309
- docs: "https://www.electron.build/linux",
310
- }, 'application Linux category is set to default "Utility"');
311
- category = "Utility";
312
- }
313
- }
314
- desktopMeta.Categories = `${category}${category.endsWith(";") ? "" : ";"}`;
315
- let data = `[Desktop Entry]`;
316
- for (const name of Object.keys(desktopMeta)) {
317
- data += `\n${name}=${desktopMeta[name]}`;
318
- }
319
- data += "\n";
320
- const desktopActions = (_g = (_f = targetSpecificOptions.desktop) === null || _f === void 0 ? void 0 : _f.desktopActions) !== null && _g !== void 0 ? _g : {};
321
- for (const [actionName, config] of Object.entries(desktopActions)) {
322
- if (!Object.keys(config !== null && config !== void 0 ? config : {}).length) {
323
- continue;
324
- }
325
- data += `\n[Desktop Action ${actionName}]`;
326
- for (const [key, value] of Object.entries(config !== null && config !== void 0 ? config : {})) {
327
- data += `\n${key}=${value}`;
328
- }
329
- data += "\n";
330
- }
331
- return Promise.resolve(data);
332
- }
333
- }
334
- exports.LinuxTargetHelper = LinuxTargetHelper;
335
- const macToLinuxCategory = {
336
- "public.app-category.graphics-design": "Graphics",
337
- "public.app-category.developer-tools": "Development",
338
- "public.app-category.education": "Education",
339
- "public.app-category.games": "Game",
340
- "public.app-category.video": "Video;AudioVideo",
341
- "public.app-category.utilities": "Utility",
342
- "public.app-category.social-networking": "Network;Chat",
343
- "public.app-category.finance": "Office;Finance",
344
- "public.app-category.music": "Audio;AudioVideo",
345
- };
346
- //# sourceMappingURL=LinuxTargetHelper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LinuxTargetHelper.js","sourceRoot":"","sources":["../../src/targets/LinuxTargetHelper.ts"],"names":[],"mappings":";;;AAAA,+CAA+F;AAC/F,+DAAiD;AACjD,uCAAqC;AACrC,uCAA+B;AAC/B,+BAA2B;AAC3B,iCAAgC;AAKhC,0CAA0C;AAC1C,kDAAkD;AAClD,kDAAkD;AAGlD;;;;;;;;;;;;;;;;GAgBG;AACH,SAAS,mBAAmB,CAAC,KAAa;IACxC,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,EAA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CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,aAAN,MAAM,cAAN,MAAM,GAAI,EAAE,CAAC,EAAE,CAAC;gBACxD,IAAI,IAAI,KAAK,GAAG,IAAI,KAAK,EAAE,CAAA;YAC7B,CAAC;YACD,IAAI,IAAI,IAAI,CAAA;QACd,CAAC;QACD,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAA;IAC9B,CAAC;CACF;AAhTD,8CAgTC;AAED,MAAM,kBAAkB,GAAQ;IAC9B,qCAAqC,EAAE,UAAU;IACjD,qCAAqC,EAAE,aAAa;IACpD,+BAA+B,EAAE,WAAW;IAC5C,2BAA2B,EAAE,MAAM;IACnC,2BAA2B,EAAE,kBAAkB;IAC/C,+BAA+B,EAAE,SAAS;IAC1C,uCAAuC,EAAE,cAAc;IACvD,6BAA6B,EAAE,gBAAgB;IAC/C,2BAA2B,EAAE,kBAAkB;CAChD,CAAA","sourcesContent":["import { asArray, exists, InvalidConfigurationError, isEmptyOrSpaces, log } from \"builder-util\"\nimport { deepAssign } from \"builder-util-runtime\"\nimport { outputFile } from \"fs-extra\"\nimport { Lazy } from \"lazy-val\"\nimport { join } from \"path\"\nimport * as semver from \"semver\"\nimport { CompressionLevel } from \"../core\"\nimport { LinuxPackager } from \"../linuxPackager\"\nimport { CommonLinuxOptions } from \"../options/linuxOptions\"\nimport { SnapCore } from \"./snap/SnapTarget\"\nimport { SnapCore24 } from \"./snap/core24\"\nimport { SnapCoreCustom } from \"./snap/coreCustom\"\nimport { SnapCoreLegacy } from \"./snap/coreLegacy\"\nimport { IconInfo } from \"../util/iconConverter\"\n\n/**\n * Escape a string value for use in a freedesktop .desktop file string field\n * (Name, Comment, StartupWMClass, etc.).\n *\n * The freedesktop Desktop Entry Specification requires that the following\n * characters be escaped in string / localestring values:\n * \\n → \\\\n (newline — would inject new key=value lines otherwise)\n * \\r → \\\\r\n * \\t → \\\\t\n * \\\\ → \\\\\\\\\n *\n * Without escaping, a productName or description containing a literal newline\n * can inject arbitrary key=value pairs into the generated .desktop file,\n * potentially overriding the Exec key.\n *\n * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#value-types\n */\nfunction desktopStringEscape(value: string): string {\n return value.replace(/\\\\/g, \"\\\\\\\\\").replace(/\\n/g, \"\\\\n\").replace(/\\r/g, \"\\\\r\").replace(/\\t/g, \"\\\\t\")\n}\n\n/**\n * Characters that require an Exec argument to be double-quoted per the\n * freedesktop Desktop Entry Specification. Plain alphanumeric args and\n * field codes must NOT be wrapped in quotes.\n *\n * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables\n */\nconst EXEC_RESERVED_RE = /[\\s\"'`\\\\<>~|&;$*?#()]/\n\n/**\n * Quote a single argument for use in a .desktop file Exec key.\n *\n * Field codes (`%f`, `%u`, `%F`, `%U`, etc.) MUST be left unquoted — the\n * desktop launcher only expands them in unquoted token positions. Wrapping\n * them in `\"…\"` causes the launcher to treat them as literal strings, which\n * breaks file-association / drag-and-drop functionality.\n *\n * For all other arguments, double-quoting is used when the argument contains\n * any character that would be misinterpreted by the launcher without quoting\n * (spaces, shell metacharacters, etc.). Safe plain-word args are passed\n * through unchanged to keep the Exec line readable.\n *\n * @see https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables\n */\nfunction desktopExecArgEscape(arg: string): string {\n // Field codes (%f, %u, %F, %U, %i, %c, %k, …) must never be quoted.\n if (/^%[a-zA-Z]$/.test(arg)) {\n return arg\n }\n // Only quote when the arg actually contains characters that need it.\n if (EXEC_RESERVED_RE.test(arg)) {\n return `\"${arg.replace(/\\\\/g, \"\\\\\\\\\").replace(/\"/g, '\\\\\"')}\"`\n }\n return arg\n}\n\nfunction mapLinuxCompressionToSnap(level: CompressionLevel | null | undefined): \"xz\" | \"lzo\" | undefined {\n if (level === \"store\") {\n return \"lzo\"\n }\n if (level === \"maximum\") {\n return \"xz\"\n }\n return undefined\n}\n\nexport const installPrefix = \"/opt\"\n\nexport class LinuxTargetHelper {\n private readonly iconPromise = new Lazy(() => this.computeDesktopIcons())\n\n private readonly mimeTypeFilesPromise = new Lazy(() => this.computeMimeTypeFiles())\n\n maxIconPath: string | null = null\n\n constructor(private packager: LinuxPackager) {}\n\n get icons(): Promise<Array<IconInfo>> {\n return this.iconPromise.value\n }\n\n get mimeTypeFiles(): Promise<string | null> {\n return this.mimeTypeFilesPromise.value\n }\n\n getSnapCore(): SnapCore<any> {\n const { snapcraft, snap: legacySnap } = this.packager.config\n if (snapcraft != null && legacySnap != null) {\n log.warn(\"Both `snapcraft` and `snap` configurations are present. `snapcraft` takes precedence; please remove the `snap` key to silence this warning.\")\n }\n\n // Merge linux-level options (category, description, mimeTypes, etc.) as the base so they\n // propagate into the generated snapcraft.yaml and .desktop file without requiring users to\n // duplicate them under core24/core18/etc. Per-core options always win for conflicts.\n // linux.compression is a CompressionLevel (\"store\"/\"normal\"/\"maximum\"); snap compression is an\n // algorithm (\"xz\"/\"lzo\"). Map the level to the nearest algorithm; per-core options override.\n const { compression: linuxCompression, ...linuxOptions } = this.packager.platformSpecificBuildOptions\n const snapLinuxOptions = { ...linuxOptions, compression: mapLinuxCompressionToSnap(linuxCompression) }\n\n if (snapcraft != null) {\n const core = snapcraft.base\n const options = snapcraft[core] || {}\n switch (core) {\n case \"core18\":\n case \"core20\":\n case \"core22\":\n if (!this.isElectronVersionGreaterOrEqualThan(\"4.0.0\")) {\n if (!this.isElectronVersionGreaterOrEqualThan(\"2.0.0-beta.1\")) {\n throw new InvalidConfigurationError(\"Electron 2 and higher is required to build Snap with core18/core20/core22\")\n }\n log.warn(null, \"electron 4 and higher is highly recommended for Snap with core18/core20/core22\")\n }\n return new SnapCoreLegacy(this.packager, this, deepAssign({}, snapLinuxOptions, { base: core, ...options }))\n case \"core24\":\n if (!this.isElectronVersionGreaterOrEqualThan(\"28.0.0\")) {\n if (!this.isElectronVersionGreaterOrEqualThan(\"25.0.0\")) {\n throw new InvalidConfigurationError(\"Electron 25 and higher is required to build Snap with core24\")\n }\n log.warn(null, \"electron 28 and higher is highly recommended for Snap with core24\")\n }\n return new SnapCore24(this.packager, this, deepAssign({}, snapLinuxOptions, options))\n case \"custom\":\n // Pass-through: do not inject linux options into user-supplied yaml\n return new SnapCoreCustom(this.packager, this, snapcraft.custom || {})\n }\n }\n\n if (legacySnap != null) {\n log.warn(\n {\n reason: \"`snap` configuration is deprecated\",\n docs: \"https://www.electron.build/snapcraft\",\n },\n \"please consider migrating `snap` configuration to `snapcraft.<core>` and remove `snap` configuration\"\n )\n }\n return new SnapCoreLegacy(this.packager, this, deepAssign({}, snapLinuxOptions, legacySnap ?? {}))\n }\n\n isElectronVersionGreaterOrEqualThan(version: string, fallback?: string): boolean {\n const electronVersion = this.packager.config.electronVersion\n if (!electronVersion) {\n return fallback ? semver.gte(fallback, version) : true\n }\n return semver.gte(electronVersion, version)\n }\n\n private async computeMimeTypeFiles(): Promise<string | null> {\n const items: Array<string> = []\n for (const fileAssociation of this.packager.fileAssociations) {\n if (!fileAssociation.mimeType) {\n continue\n }\n\n const data = `<mime-type type=\"${fileAssociation.mimeType}\">\n <glob pattern=\"*.${fileAssociation.ext}\"/>\n ${fileAssociation.description ? `<comment>${fileAssociation.description}</comment>` : \"\"}\n <icon name=\"x-office-document\" />\n</mime-type>`\n items.push(data)\n }\n\n if (items.length === 0) {\n return null\n }\n\n const file = await this.packager.getTempFile(\".xml\")\n await outputFile(\n file,\n '<?xml version=\"1.0\" encoding=\"utf-8\"?>\\n<mime-info xmlns=\"http://www.freedesktop.org/standards/shared-mime-info\">\\n' + items.join(\"\\n\") + \"\\n</mime-info>\"\n )\n return file\n }\n\n // must be name without spaces and other special characters, but not product name used\n private async computeDesktopIcons(): Promise<Array<IconInfo>> {\n const packager = this.packager\n const { platformSpecificBuildOptions, config } = packager\n\n const sources = [platformSpecificBuildOptions.icon, config.mac?.icon ?? config.icon].filter(str => !!str) as string[]\n\n // If no explicit sources are defined, fallback to buildResources directory, then default framework icon\n let fallbackSources = [...asArray(packager.getDefaultFrameworkIcon())]\n const buildResources = config.directories?.buildResources\n if (buildResources && (await exists(join(buildResources, \"icons\")))) {\n fallbackSources = [buildResources, ...fallbackSources]\n }\n\n // need to put here and not as default because need to resolve image size\n const result = await packager.resolveIcon(sources, fallbackSources, \"set\")\n this.maxIconPath = result[result.length - 1].file\n\n // Ignore .icon files for linux (they are exclusive for macOS)\n return result.filter(icon => !icon.file.endsWith(\".icon\"))\n }\n\n getDescription(options: CommonLinuxOptions) {\n return options.description || this.packager.appInfo.description\n }\n\n getSanitizedVersion(target: string) {\n const {\n appInfo: { version },\n } = this.packager\n switch (target) {\n case \"pacman\":\n return version.replace(/-/g, \"_\")\n case \"rpm\":\n case \"deb\":\n return version.replace(/-/g, \"~\")\n default:\n return version\n }\n }\n\n async writeDesktopEntry(targetSpecificOptions: CommonLinuxOptions, exec?: string, destination?: string | null, extra?: Record<string, string>): Promise<string> {\n const data = await this.computeDesktopEntry(targetSpecificOptions, exec, extra)\n const file = destination || (await this.packager.getTempFile(`${this.packager.appInfo.productFilename}.desktop`))\n await outputFile(file, data)\n return file\n }\n\n getDesktopFileName(fallback: string = this.packager.executableName): string {\n if (!this.packager.platformSpecificBuildOptions.syncDesktopName) {\n return fallback\n }\n const trimmedDesktopName = this.packager.info.metadata.desktopName?.trim()\n if (isEmptyOrSpaces(trimmedDesktopName)) {\n return fallback\n }\n const basename = trimmedDesktopName.replace(/\\.desktop$/, \"\")\n // Guard against path traversal: desktopName flows into filesystem paths\n // (snap/gui/<name>.desktop, /usr/share/applications/<name>.desktop, etc.).\n if (/[/\\\\]/.test(basename) || [...basename].some(c => c.charCodeAt(0) === 0)) {\n throw new InvalidConfigurationError(`desktopName \"${trimmedDesktopName}\" produces an invalid .desktop filename — remove any path separators or NUL characters`)\n }\n return basename\n }\n\n computeDesktopEntry(targetSpecificOptions: CommonLinuxOptions, exec?: string, extra?: Record<string, string>): Promise<string> {\n if (exec != null && exec.length === 0) {\n throw new Error(\"Specified exec is empty\")\n }\n // https://github.com/electron-userland/electron-builder/issues/3418\n if (targetSpecificOptions.desktop?.entry?.Exec) {\n throw new Error(\"Please specify executable name as linux.executableName instead of linux.desktop.Exec\")\n }\n\n const packager = this.packager\n const appInfo = packager.appInfo\n\n const executableArgs = targetSpecificOptions.executableArgs\n if (exec == null) {\n exec = `${installPrefix}/${appInfo.sanitizedProductName}/${packager.executableName}`\n if (!/^[/0-9A-Za-z._-]+$/.test(exec)) {\n exec = `\"${exec}\"`\n }\n if (executableArgs) {\n exec += \" \"\n // Each arg is double-quoted per the freedesktop Exec key spec so that\n // spaces, $, ;, & and other reserved characters are not misinterpreted.\n exec += executableArgs.map(desktopExecArgEscape).join(\" \")\n }\n // https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html#exec-variables\n const execCodes = [\"%f\", \"%u\", \"%F\", \"%U\"]\n if (executableArgs == null || executableArgs.findIndex(arg => execCodes.includes(arg)) === -1) {\n exec += \" %U\"\n }\n }\n\n // https://github.com/electron-userland/electron-builder/issues/9103\n // Electron derives app_id from desktopName in package.json; StartupWMClass must match.\n // https://github.com/electron/electron/blob/9a7b73b5334f1d72c08e2d5e94106706ed751186/lib/browser/init.ts#L128-L133\n const trimmedDesktopName = packager.info.metadata.desktopName?.trim()\n if (isEmptyOrSpaces(trimmedDesktopName)) {\n log.warn(\n {\n reason: \"desktopName is not set in package.json\",\n docs: \"https://www.electron.build/linux#window-association-desktopname--syncdesktopname\",\n },\n \"electron uses desktopName as app_id / WM_CLASS for window association. Without it desktop environments may not link running windows to this .desktop entry. Set desktopName in package.json and linux.syncDesktopName: true to fix.\"\n )\n }\n const wmClass = !isEmptyOrSpaces(trimmedDesktopName) ? trimmedDesktopName.replace(/\\.desktop$/, \"\") : appInfo.productName\n\n const desktopMeta = deepAssign<any>(\n {\n // String values are escaped per the freedesktop spec (\\\\, \\n, \\r, \\t)\n // so that a product name containing a newline cannot inject new key=value\n // pairs into the .desktop file (e.g. overriding the Exec key).\n Name: desktopStringEscape(appInfo.productName),\n Exec: exec,\n Terminal: \"false\",\n Type: \"Application\",\n Icon: packager.executableName,\n // https://askubuntu.com/questions/367396/what-represent-the-startupwmclass-field-of-a-desktop-file\n // Set to desktopName (minus .desktop suffix) when provided, so it matches Electron's\n // app_id and desktop environments can associate running windows with this entry.\n // Falls back to productName for apps that don't set desktopName.\n // to get WM_CLASS of running window: xprop WM_CLASS\n // StartupWMClass doesn't work for unicode\n // https://github.com/electron/electron/blob/2-0-x/atom/browser/native_window_views.cc#L226\n StartupWMClass: desktopStringEscape(wmClass),\n },\n extra,\n targetSpecificOptions.desktop?.entry ?? {}\n )\n\n const description = this.getDescription(targetSpecificOptions)\n if (!isEmptyOrSpaces(description)) {\n desktopMeta.Comment = desktopStringEscape(description)\n }\n\n const mimeTypes: Array<string> = asArray(targetSpecificOptions.mimeTypes)\n for (const fileAssociation of packager.fileAssociations) {\n if (fileAssociation.mimeType != null) {\n mimeTypes.push(fileAssociation.mimeType)\n }\n }\n\n for (const protocol of asArray(packager.config.protocols).concat(asArray(packager.platformSpecificBuildOptions.protocols))) {\n for (const scheme of asArray(protocol.schemes)) {\n mimeTypes.push(`x-scheme-handler/${scheme}`)\n }\n }\n\n if (mimeTypes.length !== 0) {\n desktopMeta.MimeType = mimeTypes.join(\";\") + \";\"\n }\n\n let category = targetSpecificOptions.category\n if (isEmptyOrSpaces(category)) {\n const macCategory = (packager.config.mac || {}).category\n if (macCategory != null) {\n category = macToLinuxCategory[macCategory]\n }\n\n if (category == null) {\n // https://github.com/develar/onshape-desktop-shell/issues/48\n if (macCategory != null) {\n log.warn({ macCategory }, \"cannot map macOS category to Linux. If possible mapping is known for you, please file issue to add it.\")\n }\n log.warn(\n {\n reason: \"linux.category is not set and cannot map from macOS\",\n docs: \"https://www.electron.build/linux\",\n },\n 'application Linux category is set to default \"Utility\"'\n )\n category = \"Utility\"\n }\n }\n desktopMeta.Categories = `${category}${category.endsWith(\";\") ? \"\" : \";\"}`\n\n let data = `[Desktop Entry]`\n for (const name of Object.keys(desktopMeta)) {\n data += `\\n${name}=${desktopMeta[name]}`\n }\n data += \"\\n\"\n const desktopActions = targetSpecificOptions.desktop?.desktopActions ?? {}\n for (const [actionName, config] of Object.entries(desktopActions)) {\n if (!Object.keys(config ?? {}).length) {\n continue\n }\n data += `\\n[Desktop Action ${actionName}]`\n for (const [key, value] of Object.entries(config ?? {})) {\n data += `\\n${key}=${value}`\n }\n data += \"\\n\"\n }\n return Promise.resolve(data)\n }\n}\n\nconst macToLinuxCategory: any = {\n \"public.app-category.graphics-design\": \"Graphics\",\n \"public.app-category.developer-tools\": \"Development\",\n \"public.app-category.education\": \"Education\",\n \"public.app-category.games\": \"Game\",\n \"public.app-category.video\": \"Video;AudioVideo\",\n \"public.app-category.utilities\": \"Utility\",\n \"public.app-category.social-networking\": \"Network;Chat\",\n \"public.app-category.finance\": \"Office;Finance\",\n \"public.app-category.music\": \"Audio;AudioVideo\",\n}\n"]}
@@ -1,28 +0,0 @@
1
- import { Arch } from "builder-util";
2
- import { Lazy } from "lazy-val";
3
- import { MsiOptions } from "../";
4
- import { Target } from "../core";
5
- import { FinalCommonWindowsInstallerOptions } from "../options/CommonWindowsInstallerConfiguration";
6
- import { VmManager } from "../vm/vm";
7
- import { WinPackager } from "../winPackager";
8
- export default class MsiTarget extends Target {
9
- protected readonly packager: WinPackager;
10
- readonly outDir: string;
11
- protected readonly vm: VmManager;
12
- readonly options: MsiOptions;
13
- constructor(packager: WinPackager, outDir: string, name?: string, isAsyncSupported?: boolean);
14
- protected projectTemplate: Lazy<(data: any) => string>;
15
- /**
16
- * A product-specific string that can be used in an [MSI Identifier](https://docs.microsoft.com/en-us/windows/win32/msi/identifier).
17
- */
18
- private get productMsiIdPrefix();
19
- protected get iconId(): string;
20
- protected get upgradeCode(): string;
21
- build(appOutDir: string, arch: Arch): Promise<void>;
22
- private light;
23
- private getAdditionalLightArgs;
24
- private getCommonWixArgs;
25
- protected writeManifest(appOutDir: string, wixArch: Arch, commonOptions: FinalCommonWindowsInstallerOptions): Promise<string>;
26
- protected getBaseOptions(commonOptions: FinalCommonWindowsInstallerOptions): Promise<any>;
27
- private computeFileDeclaration;
28
- }