UP | HOME

Execute command in interactive mode with Node

Use shell: true when execute command in node with spawn will let you enable interactive commands.

For example:

require('child_process').spawn("git", ["log", "--oneline"], {stdio: 'inherit', shell: true});

Date: 2019-02-24 Sun 00:00

Author: Huy Tran

Created: 2019-04-22 Mon 14:41