Electron creates MSI installer using electronic building system

I was able to create the .exe installer for Windows using Electron Builder, I create 2 package.json as indicated in the documentation:

https://github.com/electron-userland/electron-builder .

As a result, I had a folder with a working .exe enter image description here

"dist:win64": "./node_modules/.bin/build --platform win32 --arch x64" 

Assembly section of my main package.json

 "build": { "app-bundle-id": "org.test.mytest", "app-category-type": "public.app-category.graphics-design", "osx": { "contents": [ { "x": 410, "y": 150, "type": "link", "path": "/Applications" }, { "x": 130, "y": 150, "type": "file" } ] }, "win": { "title": "My awesome app", "version": "2.28.999.1", "noMsi": false, "authors": "Author" } } 

Everything works fine, I also have the .exe installer, but there is no way to install the .msi installer, which places the contents in the program files directory.

enter image description here

Instead, I finished the installation in the C: \ Users \ UserHome \ AppData \ Local \ Electron folder with the installer, as shown below.

enter image description here

Is there a way to have a real .msi installer using an electronic collector that puts the contents in a folder with a program file. The only working project is https://github.com/theodo/electron-boilerplate, but it uses the previous version of the electron assembly device.

In an electronic document setting noMsi to false, you need to achieve noMsi ...

 Should Squirrel.Windows create an MSI installer? 
+15
electron electron-builder
Apr 04 '16 at 9:30
source share
5 answers

In fact, you do not need installed MSI to install the application in Program Files .

If you disable one-click in the nsis ( oneClick ) configuration, the user will be prompted to perform a single-user installation (in AppData ) or on a computer (in Program Files ).

If you do not want to give them a choice, you can set perMachine to false, which will allow installation only in Program Files:

 "nsis": { "oneClick": false, "perMachine": false }, 

I would personally leave them the opportunity, as they can still be installed without administrator rights!

The latest version of electron-builder also has an allowToChangeInstallationDirectory option that allows the user to select any installation location.

+5
Jan 10 '17 at 12:41 on
source share

as stated on the latest electronic builder wiki , you should use the msi option in build.win :

 "build": { "app-bundle-id": "org.test.mytest", "app-category-type": "public.app-category.graphics-design", ... , "win": { "title": "My awesome app", "version": "2.28.999.1", "msi": true, "authors": "Author" } } 
+4
Jun 30 '16 at 22:24
source share

I did not get this to work (yet), but I understand that it is the other way around (terrible name).

 "noMsi": false // will make an MSI "noMsi": true // will NOT make an MSI 
+2
Apr 19 '16 at 2:42 on
source share

If you only need an installer in exe format (I do not know about msi), you can use electronic-builder to build an exe file unpacked into a directory. Check out the documentation at http://npmjs.org/package/electron-builder . The documentation is pretty simple. After you get the unzipped folder with your exe file, use the "Inno Setup Compiler" to create a professional looking installer. Once you master it, it will only take 5 minutes.

+2
03 Sep '17 at 7:27
source share

I realized this by looking at the target. to do this

 "win": { "target": [ "msi" ] //your code here }, 
0
Sep 19 '19 at 2:06
source share



All Articles