Skip to content

npmx-connector should enforce --registry when executing npm login #2179

@typed-sigterm

Description

@typed-sigterm

Describe the bug

❯ bunx npmx-connector
┌   npmx connector
│
▲  This allows npmx.dev to access your npm cli and any authenticated contexts.
│
◇  Do you accept?
│  Yes
│
●  Checking npm authentication...
(node:7228) [DEP0190] DeprecationWarning: Passing args to a child process with shell option true can lead to security vulnerabilities, as the arguments are not escaped, only concatenated.
(Use `node --trace-deprecation ...` to show where the warning was created)
│
▲  Not logged in to npm. Starting npm login...

npm notice Log in on https://registry.npmmirror.com/
Login at:
https://registry.npmmirror.com/-/v1/login/request/session/***
Press ENTER to open in the browser...

Since npmx only supports npmjs.com registry, it should execute npm login --registry=https://registry.npmjs.com/ to overrides .npmrc registry settings.

Additional context

No response

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions