I use the private npm registry for one of my npm packages, and I also have several other packages referenced by the default npm registry. What I am doing now is:
npm config set registry https:
However, this is changing the registry around the world. I can manually create .npmrc
in the root of my project and manually install the registry. This does not replace my global registry and uses a private registry for a specific project only. However, I want to do this with the command instead of manually creating .npmrc
and installing the registry.
In case you are wondering why I need this, I know how to do it myself, but I have to direct other users how to do it, and it would be easier to just give them a command. I need to know if there is a way to do something like this:
npm config --local set registry https://private.registry.endpoint
source share