Skip to content
This repository has been archived by the owner on Dec 5, 2022. It is now read-only.

How to build for distribution? #446

Open
ghost opened this issue Feb 17, 2020 · 2 comments
Open

How to build for distribution? #446

ghost opened this issue Feb 17, 2020 · 2 comments

Comments

@ghost
Copy link

ghost commented Feb 17, 2020

  • What operating system are you using? Mac OSX
  • What version of Node.js is on your system? 13.8

In the package.json are various scripts like package and package:mac

What's the process for building the application for mac and windows?

@kiranchhetri1
Copy link

No I don't have macosx

@victorhsn
Copy link

Hi @petervandeput, you can use electron-builder for distribution.

npm i -D electron-builder

After that, you can create scripts in package.json like this:

"script": {
     "mac:build": "electron-builder --macos --dir",
     "build:windows": "electron-builder --win --dir"
}

It will create a directory called dist with program-name.app and if you want to create *.dmg file, you must execute electron-builder --macos.

I hope that it can help you.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants