Skip to content

Commit

Permalink
fix: add log file names to ipc payload
Browse files Browse the repository at this point in the history
  • Loading branch information
shazron committed Oct 8, 2020
1 parent bc6b2de commit bd81226
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@ async function run (args = []) {
data: {
bin: Object.keys(pkg.bin)[0],
args,
logs: {
stdout: outFile,
stderr: errFile
},
pid: child.pid
}
}
Expand Down
4 changes: 4 additions & 0 deletions test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ test('run (with args, process.send available)', async () => {
data: {
args,
bin: 'aio-run-detached',
logs: {
stdout: `${args[0]}.out.log`,
stderr: `${args[0]}.err.log`
},
pid
},
type: 'long-running-process'
Expand Down

0 comments on commit bd81226

Please sign in to comment.