forked from olcxjas-softworks/LarpixClient
update electron to v43
This commit is contained in:
parent
68ac0beedf
commit
fb6c8b6ee9
5385 changed files with 513060 additions and 123058 deletions
41
electron/node_modules/nopt/bin/nopt.js
generated
vendored
41
electron/node_modules/nopt/bin/nopt.js
generated
vendored
|
|
@ -1,7 +1,8 @@
|
|||
#!/usr/bin/env node
|
||||
var nopt = require('../lib/nopt')
|
||||
var path = require('path')
|
||||
var types = { num: Number,
|
||||
const nopt = require('../lib/nopt')
|
||||
const path = require('path')
|
||||
console.log('parsed', nopt({
|
||||
num: Number,
|
||||
bool: Boolean,
|
||||
help: Boolean,
|
||||
list: Array,
|
||||
|
|
@ -13,8 +14,8 @@ var types = { num: Number,
|
|||
config: Boolean,
|
||||
length: Number,
|
||||
file: path,
|
||||
}
|
||||
var shorthands = { s: ['--str', 'astring'],
|
||||
}, {
|
||||
s: ['--str', 'astring'],
|
||||
b: ['--bool'],
|
||||
nb: ['--no-bool'],
|
||||
tft: ['--bool-list', '--no-bool-list', '--bool-list', 'true'],
|
||||
|
|
@ -25,32 +26,4 @@ var shorthands = { s: ['--str', 'astring'],
|
|||
c: ['--config'],
|
||||
l: ['--length'],
|
||||
f: ['--file'],
|
||||
}
|
||||
var parsed = nopt(types
|
||||
, shorthands
|
||||
, process.argv
|
||||
, 2)
|
||||
|
||||
console.log('parsed', parsed)
|
||||
|
||||
if (parsed.help) {
|
||||
console.log('')
|
||||
console.log('nopt cli tester')
|
||||
console.log('')
|
||||
console.log('types')
|
||||
console.log(Object.keys(types).map(function M (t) {
|
||||
var type = types[t]
|
||||
if (Array.isArray(type)) {
|
||||
return [t, type.map(function (mappedType) {
|
||||
return mappedType.name
|
||||
})]
|
||||
}
|
||||
return [t, type && type.name]
|
||||
}).reduce(function (s, i) {
|
||||
s[i[0]] = i[1]
|
||||
return s
|
||||
}, {}))
|
||||
console.log('')
|
||||
console.log('shorthands')
|
||||
console.log(shorthands)
|
||||
}
|
||||
}, process.argv, 2))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue