-
Notifications
You must be signed in to change notification settings - Fork 296
Closed
Description
- Version:
v6.11.4
- Platform:
Darwin Kernel Version 17.2.0: Fri Sep 29 18:27:05 PDT 2017; root:xnu-4570.20.62~3/RELEASE_X86_64 x86_64
Let's assume that we have test.sh
with content:
for item in "${list_variable[@]}"; do echo ${item}; done
and we have test.js
'use strict';
const { exec } = require('child_process');
let env = {
list_variable: ['one', 'two', 'three']
};
exec('bash test.sh', { env }, (error, stdout) => {
console.log(stdout);
});
I expect to see
one
two
three
but receiving: one,two,three
Please help me understand the root cause..
P.S. Guys from https://github.com/nodejs/node redirected me here.
Metadata
Metadata
Assignees
Labels
No labels