Hacker News new | ask | show | jobs
by Sgoettschkes 4366 days ago
Regarding 1. As far as I know, npm says in it's docs you should add node_modules to your scm because there is no way to install the exact same version through npm on different machines. On the other hand, composer has a .lock file which specifies commit hashes it installed on the dev machine, so a composer install installs the exact same commit on every machine.

@OP: You didn't commit the composer.lock. That means that your code might run locally but breaks on another machine because there might be a new version of laravel 4.2

1 comments

Can you provide a link to that? That's not how npm works at all. You specify dependencies as a dictionary: keys are package names, and values are versions. They support commit hashes, but do not require them. See: https://www.npmjs.org/doc/package.json.html#dependencies