chore: remove unused files
This commit is contained in:
parent
9ce126aee3
commit
7cdc56cfdd
303 changed files with 40 additions and 81654 deletions
|
|
@ -1,32 +0,0 @@
|
|||
const exec = require('child_process').exec
|
||||
|
||||
/**
|
||||
* Execute simple shell command (async wrapper).
|
||||
* @param {String} cmd
|
||||
* @return {Object} { stdout: String, stderr: String }
|
||||
*/
|
||||
function execCommand (cmd) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
const proc = exec(cmd, (err, stdout, stderr) => {
|
||||
if (err) {
|
||||
reject(err)
|
||||
} else {
|
||||
resolve({ stdout, stderr })
|
||||
}
|
||||
})
|
||||
|
||||
proc.stdout.on('data', data => {
|
||||
console.log(data)
|
||||
})
|
||||
|
||||
proc.stderr.on('data', data => {
|
||||
console.log(data)
|
||||
})
|
||||
|
||||
proc.on('exit', code => {
|
||||
console.log('child process exited with code ' + code.toString())
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
module.exports = { execCommand }
|
||||
Loading…
Add table
Add a link
Reference in a new issue