Node.js – can you host a private repository for your organization to use with npm

node.jsnpmrepository

Npm sounds like a great platform to use within an organization, curious if a private repo is possible, like with Nexus/Maven. Nothing comes up on Google 🙁

Best Answer

https://github.com/isaacs/npmjs.org/ : In npm version v1.0.26 you can specify private git repositories urls as a dependency in your package.json files. I have not used it but would love feedback. Here is what you need to do:

{
    "name": "my-app",
    "dependencies": {
        "private-repo": "git+ssh://git@yourgitserver.com:my-app.git#v0.0.1",
    }
}

The following post talks about this: Debuggable: Private npm modules