Closed 1001b closed 8 years ago
That is actually a cool thing that happens, when you executing jscs from the console, it goes through shell, say bash for example, which parses the stdin, so bash parses the input, not jscs, not node, but shell, which unfolds that wildcard.
But with spawn
, you bypass the shell part, so there is nobody who doing this job anymore.
Anyhow, primarily, you have two options - either use exec
or unfold that pattern yourself.
Just curiosity. The spawn approach works for ESLint. What is the implementation difference between ESLint and JSCS?
I tried to spawn a process to run jscs and ran into a problem with using "", ie, "src/". Please see below link to reproduce the error: https://github.com/1001b/jscs_spawn_issue/blob/master/index.js
The same command text runs fine directly in sh: _./nodemodules/jscs/bin/jscs -c .jscsrc src/.js*