It's common for corporate network ops to interpose a proxy between developers running on the intranet and the big bad public internet. Many command-line HTTP clients, like cURL and wget, will use the PROXY and HTTPS_PROXY environment variables to figure out there's a proxy in action, and where it is. request, used by npm-registry-client, also follows this convention when no proxy configuration is passed to it with a request. It's also common for corporate networks to have intranet or DMZ hosts to which access should not be proxied. The aforementioned command-line utilities will read a comma-delimited, semi-globbed list of these hosts from the NOPROXY environment variable. request also gained the ability to use this configuration in the not too distant past. It also relies upon no proxy information being passed to request -- even if there is an object property set to `null`. But what if you want to override proxy settings at the command line? Before this change, there was no way to communicate to npm-registry-client that it should tell request not to read the proxy configuration from the environment. To get that information into npm-registry-client, it now looks for the HTTP proxy to be set to false. How the npm CLI gets that information to the client is a bit of movie magic that doesn't bear overly close examination (it relies heavily on the near-abuse of nopt's flexibility), but it does the trick. Also include some tests, because this corner of the client is pretty terribly underspecified and underdocumented. Let's hope there aren't too many more of these edge cases lurking about.
Depends on `npm-package-arg` to only escape slashes in scoped package names. The additional level of indirection between the registry client prototype and the distTags methods necessitated some prototype chain hackery I'm none too proud of, but it's documented and works. The client is due for another rewrite anyway.