1
0
mirror of https://github.com/jiahaog/Nativefier synced 2024-06-26 07:38:59 +02:00

Merge pull request #26 from Ivshti/patch-2

Validate the --arch argument
This commit is contained in:
Max Ogden 2015-05-11 12:08:18 -07:00
commit d32cf1034f

View File

@ -18,6 +18,12 @@ module.exports = function packager (opts, cb) {
if (!platform || !arch || !version) cb(new Error('Must specify platform, arch and version'))
switch (arch) {
case 'ia32': break
case 'x64': break
default: cb(new Error('Unsupported arch'))
}
switch (platform) {
case 'darwin': packager = mac; break
case 'linux': packager = linux; break