mirror of
https://github.com/overte-org/overte.git
synced 2025-04-19 16:23:39 +02:00
Add getLogs to Process
This commit is contained in:
parent
ab516f6543
commit
8a4855c411
1 changed files with 8 additions and 2 deletions
|
@ -245,13 +245,19 @@ Process.prototype = extend(Process.prototype, {
|
|||
}
|
||||
return false;
|
||||
},
|
||||
getLogs: function() {
|
||||
var logs = {};
|
||||
logs[this.child.pid] = {
|
||||
stdout: this.logStdout == 'ignore' ? null : this.logStdout,
|
||||
stderr: this.logStderr == 'ignore' ? null : this.logStderr
|
||||
};
|
||||
return logs;
|
||||
},
|
||||
|
||||
// Events
|
||||
onChildStartError: function(error) {
|
||||
console.log("Child process error ", error);
|
||||
this.state = ProcessStates.STOPPED;
|
||||
this.emit('state-update', this);
|
||||
this.updateState(ProcessStates.STOPPED);
|
||||
},
|
||||
onChildClose: function(code) {
|
||||
console.log("Child process closed with code ", code, this.name);
|
||||
|
|
Loading…
Reference in a new issue