IndigoUnited/node-cross-spawn — pull request #5 by laggingreflex (2014-08-13 02:52:08+00:00)
Title: multiple comands in single line like "git init && git remote add ..."  not working on windows

I have a multiple command in a single line.

git init && git remote add origin address

I'm not sure whether there's any other way I should be doing it.
The yeoman generator uses this in its `generator.spawnCommand` and I need to execute my commands in order and I've found that passing in different `spawnCommand` doesn't ensure that.

But this gives error "usage: git init [-q | --quiet] [-...". I guess it somehow sends the "` && git remote...`" as an argument to `git init`.

Luckily, it executes if I pass the command as `cmd /c git init && git remote add ...`. Which seems unnecessary and redundant but it works!

What also works is NOT Escaping command & arguments in the source (attached pull request). Not sure if this is acceptable but it works.