diff --git a/readme.md b/readme.md index 2ec9b42..93b2152 100644 --- a/readme.md +++ b/readme.md @@ -51,7 +51,60 @@ This will: You should be able to launch the app on the platform you built for. If not, check your settings and try again. -**Be careful** not to include node_modules you don't want into your final app. For example, do not include the `node_modules/electron-packager` folder or `node_modules/electron-prebuilt`. You can use `--ignore=node_modules/electron-prebuilt` to ignore of these +**Be careful** not to include node_modules you don't want into your final app. `Electron-packager`, `electron-prebuilt` and `.git` will be ignored by default. You can use `--ignore` to ignore files and folders, e.g. `--ignore=node_modules/electron-packager`. + +### API +```javascript +var packager = require('electron-packager') +packager(opts, function done (err, appPath) { + +}) +``` +#### packager(opts, callback) + +##### opts +**Required** +`dir` - *String* +The source directory. + +`name` - *String* +The application name. + +`platform` - *String* +Allowed values: *linux, win32, darwin* + +`arch` - *String* +Allowed values: *ia32, x64* + +`version` - *String* +Semver, see https://github.com/atom/electron/releases + +**Optional** +`out` - *String* + +`icon` - *String* + +`app-bundle-id` - *String* + +`app-versionv` - *String* + +`helper-bundle-id` - *String* + +`ignore` - *String* + +`prune` - *Boolean* + +`asar` - *Boolean* + +`sign` - *String* + +##### callback + +`err` - *Error* +Contains errors if any. + +`appPath` - *String* +Path to the newly created application. ### Building windows apps from non-windows platforms