mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2024-11-10 15:21:03 +00:00
Add set version support
This commit is contained in:
parent
a6cf85d0f6
commit
40f881a718
5
index.js
5
index.js
@ -57,6 +57,7 @@ module.exports = function packager (opts, cb) {
|
|||||||
|
|
||||||
var bundleId = opts['app-bundle-id'] || 'com.atom-shell.' + opts.name.toLowerCase()
|
var bundleId = opts['app-bundle-id'] || 'com.atom-shell.' + opts.name.toLowerCase()
|
||||||
var bundleHelperId = opts['helper-bundle-id'] || 'com.atom-shell.' + opts.name.toLowerCase() + '.helper'
|
var bundleHelperId = opts['helper-bundle-id'] || 'com.atom-shell.' + opts.name.toLowerCase() + '.helper'
|
||||||
|
var appVersion = opts['app-version']
|
||||||
|
|
||||||
pl1.CFBundleDisplayName = opts.name
|
pl1.CFBundleDisplayName = opts.name
|
||||||
pl1.CFBundleIdentifier = bundleId
|
pl1.CFBundleIdentifier = bundleId
|
||||||
@ -64,6 +65,10 @@ module.exports = function packager (opts, cb) {
|
|||||||
pl2.CFBundleIdentifier = bundleHelperId
|
pl2.CFBundleIdentifier = bundleHelperId
|
||||||
pl2.CFBundleName = opts.name
|
pl2.CFBundleName = opts.name
|
||||||
|
|
||||||
|
if (appVersion) {
|
||||||
|
pl1.CFBundleVersion = appVersion
|
||||||
|
}
|
||||||
|
|
||||||
if (opts.protocols) {
|
if (opts.protocols) {
|
||||||
pl2.CFBundleURLTypes = pl1.CFBundleURLTypes = opts.protocols.map(function (protocol) {
|
pl2.CFBundleURLTypes = pl1.CFBundleURLTypes = opts.protocols.map(function (protocol) {
|
||||||
return {
|
return {
|
||||||
|
@ -43,6 +43,7 @@ these are optional CLI options you can pass in
|
|||||||
- `out` (default current working dir) - the dir to put the app into at the end
|
- `out` (default current working dir) - the dir to put the app into at the end
|
||||||
- `version` (default hardcoded in source) - atom-shell version to use
|
- `version` (default hardcoded in source) - atom-shell version to use
|
||||||
- `app-bundle-id` - bundle identifier to use in the app plist
|
- `app-bundle-id` - bundle identifier to use in the app plist
|
||||||
|
- `app-version` - version to set for the app
|
||||||
- `helper-bundle-id` - bundle identifier to use in the app helper plist
|
- `helper-bundle-id` - bundle identifier to use in the app helper plist
|
||||||
- `ignore` (default none) - do not copy files into App whose filenames regex .match this string
|
- `ignore` (default none) - do not copy files into App whose filenames regex .match this string
|
||||||
- `prune` - runs `npm prune --production` on the app
|
- `prune` - runs `npm prune --production` on the app
|
||||||
|
Loading…
Reference in New Issue
Block a user