Wednesday, 26 April 2017

Which shell npm is using when running npm scripts?

I am on Windows running fish shell through ConEmu. Fish by default doesn't recognize "&&" operator however having this:

"scripts": {
  "test": "echo 'a' && echo 'b'"
}

and running "npm run test" is working. So I thought it must be using default "cmd" and this is what npm config ls -l | grep shell says, however.... When I change "test" script to:

"scripts": {
  "test": "echo 'a' && ls"
}

this also works while ls is clearly not supported in "cmd".

What the hell is going here? 😲



via apieceofbart

No comments:

Post a Comment