I am trying to install my node project to run online however when i try to push to heroku master I get errors. I followed these steps: https://devcenter.heroku.com/articles/getting-started-with-nodejs#push-local-changes the first error is:
remote: > node lib/install.js
remote:
remote: module.js:338
remote: throw err;
remote: ^
remote: Error: Cannot find module 'spawn-sync'
remote: at Function.Module._resolveFilename (module.js:336:15)
remote: at Function.Module._load (module.js:278:25)
remote: at Module.require (module.js:365:17)
remote: at require (module.js:384:17)
remote: at Object.<anonymous> check/index.js:5:17)
I tried to install de module with npm install spawn-sync --save
and runned git add -A
and git commit -m "added spawn-sync"
and again tried to git push heroku master
but the error keeps coming up. I'm working in a branch and i'm in the root folder of my application. Does anyone know how to fix this
Make sure you're on the master branch. If you're not working on master
, you should push to heroku like git push heroku branchYouAreOn:master
.
Make sure spawn-sync
is listed in dependencies
in your package.json file.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.