Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

nvm is my solution to this

It isolate and pins npm installs so that the environment is the same in the future without messing up your main system

Your projects also need to consider pinning their dependencies to a specific version

Other languages/frameworks with package managers have similar concepts



> Your projects also need to consider pinning their dependencies to a specific version

At that point, you should consider just using your version control system to handle versioning instead of trying to route around it, poorly.


As a long-time ruby user where bundler has done version pinning for decades, I think this is a core feature of any dependency management system, not some kind of "routing around it."

I'm not sure what "your own version control system" means. Checking all dependencies into (eg) git? I'm not sure how you deal with indirect/second-level dependencies, but any kind of roll your own like that to me is what I'd call "routing around" the failures of your platform dependency management system.

Correct dependency pinning also allows you automated ways to upgrade dependencies, resolving requirement trees, within stated bounds specified per-dependency (like keep to same major version). It just happens when you want, not every time you install or deploy.


> I'm not sure what "your own version control system" means.

Me neither. Where did that come from? I didn't write it. (It's not in my comment, just yours.)


Ah apparently my brain inserted `own`, looking back you said "just using your version control system". OK, I think I'd write the rest of my comment the same still; does it mean putting all your dependencies (source/binary) in your version control (eg) git?


Yes—using your VCS/SCM to version control the source code.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: