Closed rufuspollock closed 10 years ago
Yes, I agree that they shouldn't be committed to the repository. But it's recommended by both Heroku and npm to commit your dependencies in case npm goes down during a deploy. That said, although it would be annoying we can always temporarily commit them when we did a deploy during npm downtime. I'll have a look tonight and remove the node_modules
and clean up my express PR.
In Python you can set a cache folder which is checked in so that when you pip install it uses that cache folder instead of, or after failing to connect to, the remote repo. Does npm have something similar?
Yes, npm works similarly. The node_modules
folder contains a local copy of the dependencies.
My preference would be to remove the node_modules
folder completely as there might come a point where we're using a dependency that needs to be compiled or has some C extensions.
This is a labs project. It doesn't really matter if you can't deploy it for a couple hours while npm is down :)
Also - Please Stop Compiling Things As Part Of Your Deployment Procedure.
P.S. what is a webshot?
@simong I agree with you on complete removal of node_modules folder from the repo - let's do it :-)
@davidmiller info on what webshot is can be found at https://github.com/okfn/ideas/issues/63 :-)
FIXED
We probably not have node_modules committed to the repo - we can just run
npm install
to setup. Suggest: