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

Commit

Permalink
doc(readme): include packaging instructions using electron-packager (#…
Browse files Browse the repository at this point in the history
…693)

* Update README.md to add packaging instructions

Include packaging instructions using electron-packager.

Add Note that "main" in package.json needs to be changed to 'index.js' for packaging to succeed.

NOTE: this README.md update should also be applied to the skeleton-esnext README, since both appear to have the same instructions for running within Electron.

* Update README.md to add packaging instructions

Include packaging instructions using electron-packager.

Add Note that "main" in package.json needs to be changed to 'index.js' for packaging to succeed.
  • Loading branch information
devhammer authored and niieani committed Oct 14, 2016
1 parent c011c1e commit 0379d21
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
23 changes: 23 additions & 0 deletions skeleton-esnext/README.md
Expand Up @@ -103,6 +103,29 @@ To run the app under [Electron](http://electron.atom.io), follow these steps.
electron .
```

## Packaging The App Using Electron-Packager

>**Note:** The electron-packager package relies on `"main"` in package.json to know which JS file to use to start the application. To make this work with electron-packager change this line in package.json from `"main": "dist/main.js",` to `"main": "index.js",`
1. Follow steps 1-6 in the previous section (Running The App under Electron).

2. Install electron-packager

```shell
npm install electron-packager -g
```

3. Run the command:

```shell
electron-packager <sourcedir> <appname> --platform=<platform> --arch=<arch> --version <electron version #> [optional flags...]
```
Include the `--asar` option to create an [asar archive](http://electron.atom.io/docs/tutorial/application-packaging/) from your app.

By default, electron-packager will place the packaged app in a folder under the source folder with the naming convention of `<appname>-<platform>-<arch>`.

See the [electron-packager](https://github.com/electron-userland/electron-packager) readme for more details on options.


## Bundling
Bundling is performed by [Aurelia Bundler](http://github.com/aurelia/bundler). A gulp task is already configured for that. Use the following command to bundle the app:
Expand Down
23 changes: 23 additions & 0 deletions skeleton-typescript/README.md
Expand Up @@ -103,6 +103,29 @@ To run the app under [Electron](http://electron.atom.io), follow these steps.
electron .
```

## Packaging The App Using Electron-Packager

>**Note:** The electron-packager package relies on `"main"` in package.json to know which JS file to use to start the application. To make this work with electron-packager change this line in package.json from `"main": "dist/main.js",` to `"main": "index.js",`
1. Follow steps 1-6 in the previous section (Running The App under Electron).

2. Install electron-packager

```shell
npm install electron-packager -g
```

3. Run the command:

```shell
electron-packager <sourcedir> <appname> --platform=<platform> --arch=<arch> --version <electron version #> [optional flags...]
```
Include the `--asar` option to create an [asar archive](http://electron.atom.io/docs/tutorial/application-packaging/) from your app.

By default, electron-packager will place the packaged app in a folder under the source folder with the naming convention of `<appname>-<platform>-<arch>`.

See the [electron-packager](https://github.com/electron-userland/electron-packager) readme for more details on options.


## Bundling
Bundling is performed by [Aurelia Bundler](http://github.com/aurelia/bundler). A gulp task is already configured for that. Use the following command to bundle the app:
Expand Down

0 comments on commit 0379d21

Please sign in to comment.