title: Can I set npm to use a .pac file?
body: <p>I am trying to set a private registry for npm (nodejs) but I don't want to replicate the entire public database. I have seen posts about how to do this, however, I have another problem even if I follow this approach. My workstation is behind a VPN, so I need to set the proxy in NPM to be able to get modules from the public registry. If I create my private registry, it would sit inside the company VPN (making it publicly accessible is not an option). This means that I do not need the proxy to access my private registry, but like I said before, I do need it for the public registry.
  I got the code for NPM from git, but before modifying it, I thought I would just ask, does anyone know how to get around this issue? I know you can specify registry and proxy when running npm install, but I want to be able to just run npm install.
  Is there anyway to apply a pac file to npm? Is there something that I can do besides modifying the source code?</p>