Comparing version 0.8.87 to 0.8.88
@@ -30,3 +30,3 @@ { | ||
"ora": "^2.0.0", | ||
"tap": "^10.1.0", | ||
"tap": "^14.10.6", | ||
"uglify-js": "^3.2.1", | ||
@@ -81,3 +81,3 @@ "webpack": "^2.6.1", | ||
"name": "febs-browser", | ||
"version": "0.8.87" | ||
"version": "0.8.88" | ||
} |
@@ -19,25 +19,3 @@ { | ||
"devDependencies": { | ||
"babel-core": "^6.26.0", | ||
"babel-loader": "^6.4.1", | ||
"babel-plugin-istanbul": "^4.1.6", | ||
"babel-plugin-transform-es2015-modules-simple-commonjs": "^0.3.0", | ||
"babel-plugin-transform-es3-member-expression-literals": "^6.22.0", | ||
"babel-plugin-transform-es3-property-literals": "^6.22.0", | ||
"babel-plugin-transform-runtime": "^6.23.0", | ||
"babel-polyfill": "^6.26.0", | ||
"babel-preset-env": "^1.6.1", | ||
"babel-preset-es2015": "^6.24.1", | ||
"babel-preset-es2015-loose": "^8.0.0", | ||
"babel-preset-stage-0": "^6.24.1", | ||
"babel-preset-stage-1": "^6.24.1", | ||
"babel-preset-stage-2": "^6.24.1", | ||
"babel-runtime": "^6.26.0", | ||
"es3ify-loader": "^0.2.0", | ||
"es3ify-webpack-plugin": "0.0.1", | ||
"es5-shim": "^4.5.10", | ||
"es6-promise": "^4.2.4", | ||
"ora": "^2.0.0", | ||
"tap": "^10.1.0", | ||
"uglify-js": "^3.2.1", | ||
"webpack": "^2.6.1" | ||
"tap": "^14.10.6" | ||
}, | ||
@@ -91,3 +69,3 @@ "directories": {}, | ||
"name": "febs", | ||
"version": "0.8.87" | ||
"version": "0.8.88" | ||
} |
@@ -172,7 +172,18 @@ 'use strict'; | ||
*/ | ||
exports.execCommand = function execCommand(cmdString, params, cbFinish) { | ||
exports.execCommand = function execCommand(cmdString, params, optionOrCbFinish, cbFinish) { | ||
var option; | ||
if (typeof optionOrCbFinish === 'function') { | ||
cbFinish = paramsOrOption; | ||
} | ||
else if (typeof optionOrCbFinish === 'object') { | ||
option = optionOrCbFinish; | ||
} | ||
if (!option) option = {}; | ||
// scripts. | ||
let cms = cmdString.split(' '); | ||
let cmps = cms[0]; | ||
let inputps = cms.splice(1); | ||
var cms = cmdString.split(' '); | ||
var cmps = cms[0]; | ||
var inputps = cms.splice(1); | ||
if (cmdString.indexOf('&') >= 0) { | ||
@@ -184,3 +195,3 @@ cmps = cmdString; | ||
if (!inputps) { | ||
exec(cmps, function(err){ | ||
exec(cmps, option, function(err){ | ||
if (cbFinish) cbFinish(err); | ||
@@ -197,3 +208,4 @@ if (err) { | ||
var proc = spawn(cmps, inputps, {stdio: 'inherit'}); | ||
option = mergeMap( {stdio: 'inherit'}, option); | ||
var proc = spawn(cmps, inputps, option); | ||
proc.on('close', function (code) { | ||
@@ -200,0 +212,0 @@ if (code !== 0) { |
@@ -717,2 +717,9 @@ // Type definitions for febs | ||
function execCommand(cmd:string, params:string[], cbFinish:(err:any)=>void):void; | ||
/** | ||
* @desc: 执行cmd. | ||
* @param cmd: 指令. | ||
* @param params: 输入参数数组. | ||
* @param cbFinish: 完成的回调. | ||
*/ | ||
function execCommand(cmd:string, params:string[], options:{cwd?:string}, cbFinish:(err:any)=>void):void; | ||
} | ||
@@ -719,0 +726,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
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
1
3099492
71
34183
6