2016-07-21 7 views

答えて

0

あなたはchild_processexec

var exec = require('child_process').exec; 

exec('./yourscript.sh <args>', 
    function (error, stdout, stderr) { 
    console.log('stdout: ' + stdout); 
    console.log('stderr: ' + stderr); 
    if (error !== null) { 
     console.log('exec error: ' + error); 
    } 
}); 
を使ってNode.jsの中でbashスクリプトを実行することができます
関連する問題