To pack up your Electron proyect in windows, you will need to install a dependency in a electron proyect still created.
This dependency is called electron-builder. The installation command it is the following:
npm install --save-dev electron-builder
Secondly, it is necessary make a build of our proyect so you need to execute this command:
npm run build:win
Thirdly, if you want to pack up your proyect, you will put in file package.json, in the section scripts this script:
"electron-pack": "npm run build && electron-builder"
Finnaly, for pack up your proyect, you will execute this command:
npm run electron-pack
The installer it will be installed in the dist directory and the name of your aplication installer it will be something like this name [your_electron_proyect_name]-[version]-setup.exe.
For install your app in your device you only need to click in the file named before and it will be installed in your Desktop directory.
Top comments (0)