I have a simple node js program named test_cmd.js. I want to run this program through a unix shell, and use the output of the program to execute a unix command.
test_cmd.js can simply be:
console.log('echo "hello, world!"'); Output:
>> pi@raspberrypi ~/ $ node test_cmd.js >> echo "hello, world!" # I want the unix shell I just ran this program in to run this output as a command, but how?