Skip to content

npm whoami fails when .npmrc has custom registry #764

Open
@fisker

Description

@fisker

Description

Steps to reproduce

  1. Add custom registry to .npmrc
  2. Add publishConfig with NPM registry https://registry.npmjs.org/
  3. Run np
You must be logged in. Use `npm login` and try again.

Expected behavior

externalRegistry: isExternalRegistry ? package_.publishConfig.registry : false,
should use registry from publishConfig even it's not external registry, otherwise NPM will read .npmrc

Environment

np - 10.2.0
Node.js - 10.2.0
npm - 10.7.0
Git - git version 2.42.0.windows.2
OS - Windows 10

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions