Exit status 2 on "npm run dev"
See original GitHub issueHi,
First of all thanks for laravel-mix. However I can’t get it to work.
My steps:
npm install
- Updated
node
andnpm
to latest versions - Update
laravel-mix
to0.5.1
- Updated
webpack.mix.js
to match thefix
branch on the Laravel repo
Every time I run npm run dev
I get the below error. Any idea what it could be?
Full stack trace:
npm verb lifecycle @~dev: unsafe-perm in lifecycle true
npm verb lifecycle @~dev: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/bobbybouwmann/OpenSource/vault/node_modules/.bin:/Users/bobbybouwmann/.composer/vendor/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/MacGPG2/bin:/Users/bobbybouwmann/.composer/vendor/bin
npm verb lifecycle @~dev: CWD: /Users/bobbybouwmann/OpenSource/vault
npm info lifecycle @~dev: Failed to exec dev script
npm verb stack Error: @ dev: `cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm verb stack Exit status 2
npm verb stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:279:16)
npm verb stack at emitTwo (events.js:106:13)
npm verb stack at EventEmitter.emit (events.js:191:7)
npm verb stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)
npm verb stack at emitTwo (events.js:106:13)
npm verb stack at ChildProcess.emit (events.js:191:7)
npm verb stack at maybeClose (internal/child_process.js:885:16)
npm verb stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
npm verb pkgid @
npm verb cwd /Users/bobbybouwmann/OpenSource/vault
npm ERR! Darwin 15.6.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "dev" "--verbose"
npm ERR! node v7.4.0
npm ERR! npm v4.1.1
npm ERR! code ELIFECYCLE
npm ERR! @ dev: `cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @ dev script 'cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the 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 webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls
npm ERR! There is likely additional logging output above.
npm verb exit [ 1, true ]
npm ERR! Please include the following file with any support request:
npm ERR! /Users/bobbybouwmann/OpenSource/vault/npm-debug.log
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Exit status 2 on "npm run dev" · Issue #127 - GitHub
Hi, First of all thanks for laravel-mix. However I can't get it to work. My steps: npm install Updated node and npm to...
Read more >Exit status 2 when run webpack prod in jhipster - Stack Overflow
I have a problem when build production with jhipster. Throw error when run webpack prod. I am running on my dev pc.
Read more >Debugging "Make Failed with Exit Code 2" Error - CodeForGeek
The “Make Failed with Exit Code 2” error occurs during the node modules installation. We see lots of stack trace including the one...
Read more >Error when running npm install && npm run dev - Laracasts
have a fresh installation of laravel and I've installed npm. but when I run npm install && npm run dev I get this...
Read more >concurrently - npm
Start using concurrently in your project by running `npm i ... must exit with code 0 in order for concurrently exit with code...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
i try update node, npm to latest
but not working
and then i added babel-preset-es2015 => it working 💃 this command:
I hope, i can help someone!
😉