registry-url.js 231 B

12345
  1. module.exports = function (scope, npmrc) {
  2. var rc = npmrc || require('rc')('npm', { registry: 'https://registry.npmjs.org/' })
  3. var url = rc[scope + ':registry'] || rc.registry
  4. return url.slice(-1) === '/' ? url : url + '/'
  5. }