react-boilerplate: cross-env: command not found

I’m running node 4.4.5 locally. Cloned the repo, ran setup command without issue. On ‘npm run start’ I get an error:

react-boilerplate@3.0.0 start /Users/kdolbear/Documents/Jobs/mower/react-boilerplate npm run start:tunnel

react-boilerplate@3.0.0 start:tunnel /Users/kdolbear/Documents/Jobs/mower/react-boilerplate cross-env NODE_ENV=development node server

sh: cross-env: command not found

npm ERR! Darwin 15.5.0 npm ERR! argv “/usr/local/bin/node” “/usr/local/bin/npm” “run” “start:tunnel” npm ERR! node v4.4.5 npm ERR! npm v2.15.5 npm ERR! file sh npm ERR! code ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall spawn npm ERR! react-boilerplate@3.0.0 start:tunnel: cross-env NODE_ENV=development node server npm ERR! spawn ENOENT npm ERR! npm ERR! Failed at the react-boilerplate@3.0.0 start:tunnel script ‘cross-env NODE_ENV=development node server’. npm ERR! This is most likely a problem with the react-boilerplate package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! cross-env NODE_ENV=development node server npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs react-boilerplate npm ERR! Or if that isn’t available, you can get their info via: npm ERR! npm ERR! npm owner ls react-boilerplate npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /Users/kdolbear/Documents/Jobs/mower/react-boilerplate/npm-debug.log

npm ERR! Darwin 15.5.0 npm ERR! argv “/usr/local/bin/node” “/usr/local/bin/npm” “run” “start” npm ERR! node v4.4.5 npm ERR! npm v2.15.5 npm ERR! code ELIFECYCLE npm ERR! react-boilerplate@3.0.0 start: npm run start:tunnel npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the react-boilerplate@3.0.0 start script ‘npm run start:tunnel’. npm ERR! This is most likely a problem with the react-boilerplate package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! npm run start:tunnel npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs react-boilerplate npm ERR! Or if that isn’t available, you can get their info via: npm ERR! npm ERR! npm owner ls react-boilerplate npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /Users/kdolbear/Documents/Jobs/mower/react-boilerplate/npm-debug.log

And here’s the log: 0 info it worked if it ends with ok 1 verbose cli [ ‘/usr/local/bin/node’, ‘/usr/local/bin/npm’, ‘run’, ‘start’ ] 2 info using npm@2.15.5 3 info using node@v4.4.5 4 verbose run-script [ ‘prestart’, ‘start’, ‘poststart’ ] 5 info prestart react-boilerplate@3.0.0 6 info start react-boilerplate@3.0.0 7 verbose unsafe-perm in lifecycle true 8 info react-boilerplate@3.0.0 Failed to exec start script 9 verbose stack Error: react-boilerplate@3.0.0 start: npm run start:tunnel 9 verbose stack Exit status 1 9 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:217:16) 9 verbose stack at emitTwo (events.js:87:13) 9 verbose stack at EventEmitter.emit (events.js:172:7) 9 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:24:14) 9 verbose stack at emitTwo (events.js:87:13) 9 verbose stack at ChildProcess.emit (events.js:172:7) 9 verbose stack at maybeClose (internal/child_process.js:827:16) 9 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5) 10 verbose pkgid react-boilerplate@3.0.0 11 verbose cwd /Users/kdolbear/Documents/Jobs/mower/react-boilerplate 12 error Darwin 15.5.0 13 error argv “/usr/local/bin/node” “/usr/local/bin/npm” “run” “start” 14 error node v4.4.5 15 error npm v2.15.5 16 error code ELIFECYCLE 17 error react-boilerplate@3.0.0 start: npm run start:tunnel 17 error Exit status 1 18 error Failed at the react-boilerplate@3.0.0 start script ‘npm run start:tunnel’. 18 error This is most likely a problem with the react-boilerplate package, 18 error not with npm itself. 18 error Tell the author that this fails on your system: 18 error npm run start:tunnel 18 error You can get information on how to open an issue for this project with: 18 error npm bugs react-boilerplate 18 error Or if that isn’t available, you can get their info via: 18 error 18 error npm owner ls react-boilerplate 18 error There is likely additional logging output above. 19 verbose exit [ 1, true ]

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 16 (3 by maintainers)

Most upvoted comments

npm install cross-env will fix your problems! I wonder why that’s not installed…

As I mentioned above, in trying to fix the issue I had upgraded Node locally. I did a little searching on NPM issues and found this. I manually removed Node and NPM, then did a clean install of 6.2.1, cloned the boilerplate repo and everything works perfectly.

Thanks for the prompt reply. I installed cross-env, restarted CLI, re-cloned repo just to be sure I had a clean slate and am getting the same error as before.