const Interface = require('./cli');
// Create CLInterface
var cli = new Interface({ version: '1.0.0', outfn: console.log });
cli
.command('add', {
params: '[Number] [Number]',
description: 'Adds two numbers'
})
.option('t', 'third', '[number3]', 'Adds a third number')
.option({long: 'morefive', desc: 'Adds more 5'})
.callBack(function(opts, n1, n2) {
var n3 = opts.get('third', Number),
n5 = opts.has('morefive'),
sum = Number(n1) + Number(n2);
if (n3) sum += n3;
if (n5) sum += 5;