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

Commit

Permalink
fix: error if identifier is not set
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Apr 27, 2018
1 parent 6f27303 commit 9de6c28
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/commands/pack/macos.ts
Expand Up @@ -13,7 +13,7 @@ export default class PackMacos extends Command {
}

async run() {
if (process.platform !== 'darwin') throw new Error('must be run from macos')
if (process.platform !== 'darwin') this.error('must be run from macos')
const {flags} = this.parse(PackMacos)
const buildConfig = await Tarballs.buildConfig(flags.root)
const {config} = buildConfig
Expand All @@ -29,6 +29,7 @@ export default class PackMacos extends Command {
await writeScript('preinstall')
await writeScript('postinstall')
const c = config.pjson.oclif as any
if (!c.macos || !c.macos.identifier) this.error('package.json must have oclif.macos.identifier set')
const args = [
'--root', buildConfig.workspace({platform: 'darwin', arch: 'x64'}),
'--identifier', c.macos.identifier,
Expand Down

0 comments on commit 9de6c28

Please sign in to comment.