1

I'm having an issue at work that I can't seem to pinpoint the root cause. We have scripts we run via npm in angular to get a local instance of a server running. It seems like on some coworkers pcs the command errors. It seems to related to linux. See here. It is the same error but ANGULAR_ENV instead of NODE_ENV. Does anyone have any idea why it would work on some pcs but not others? Command is as follows npm run-script dev:external

jawn
  • 851
  • 7
  • 10
  • Presumably because some of you are using e.g. git bash or other *nix-like command lines, and others are using a Windows shell. I'd suggest using `cross-env` or similar so that environment variables are handled consistently everywhere. – jonrsharpe May 18 '21 at 16:40
  • @jonrsharpe I thought that as well, but it didn't matter whether it was done in gitbash, visual studio terminal, or cmd. We had to run the following script config set script-shell "C:\Program Files\Git\bin\bash.exe" – jawn May 19 '21 at 00:38

1 Answers1

0

It looks like this did it:

config set script-shell "C:\Program Files\Git\bin\bash.exe"
jawn
  • 851
  • 7
  • 10