@untool/yargs
Advanced tools
Comparing version 0.4.3 to 0.5.0
@@ -6,2 +6,10 @@ # Change Log | ||
<a name="0.5.0"></a> | ||
# [0.5.0](https://github.com/untool/untool/compare/v0.4.3...v0.5.0) (2018-05-07) | ||
**Note:** Version bump only for package @untool/yargs | ||
<a name="0.4.3"></a> | ||
@@ -8,0 +16,0 @@ ## [0.4.3](https://github.com/untool/untool/compare/v0.4.2...v0.4.3) (2018-04-24) |
/* eslint-disable no-console */ | ||
const chalk = require('chalk'); | ||
const { sync: { pipe, override } } = require('mixinable'); | ||
const { sync: { pipe, sequence, override } } = require('mixinable'); | ||
@@ -10,13 +10,12 @@ const { Mixin } = require('@untool/core'); | ||
registerCommands(yargs) { | ||
yargs.option('log', { | ||
return yargs.option('log', { | ||
alias: 'l', | ||
default: 'info', | ||
describe: 'Define log level ()', | ||
describe: 'Define log level', | ||
type: 'string', | ||
}); | ||
return yargs; | ||
} | ||
handleArguments(argv) { | ||
const levels = ['debug', 'info', 'warn', 'error', 'silent']; | ||
const index = levels.indexOf(argv.log || argv.l); | ||
const index = levels.indexOf(argv.log); | ||
this.levels = levels.slice(Math.max(index, 0), -1); | ||
@@ -65,6 +64,3 @@ } | ||
registerCommands: pipe, | ||
handleArguments: function(functions, ...args) { | ||
functions.forEach(fn => fn(...args)); | ||
return true; | ||
}, | ||
handleArguments: sequence, | ||
logDebug: override, | ||
@@ -71,0 +67,0 @@ logInfo: override, |
{ | ||
"name": "@untool/yargs", | ||
"version": "0.4.3", | ||
"version": "0.5.0", | ||
"description": "untool yargs mixin", | ||
@@ -28,3 +28,3 @@ "keywords": [ | ||
"dependencies": { | ||
"@untool/core": "^0.4.3", | ||
"@untool/core": "^0.5.0", | ||
"chalk": "^2.3.1", | ||
@@ -31,0 +31,0 @@ "mixinable": "^2.0.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8979
94
+ Added@untool/core@0.5.0(transitive)
+ Addedcaller-callsite@2.0.0(transitive)
+ Addedcaller-path@2.0.0(transitive)
+ Addedcallsites@2.0.0(transitive)
+ Addedcosmiconfig@5.2.1(transitive)
+ Addedimport-fresh@2.0.0(transitive)
+ Addedresolve-from@3.0.0(transitive)
- Removed@untool/core@0.4.3(transitive)
- Removedcosmiconfig@4.0.0(transitive)
- Removedrequire-from-string@2.0.2(transitive)
Updated@untool/core@^0.5.0