Skip to content

Cannot remove auto-installed node versions #8357

Description

@LeviticusMB

Verify latest release

  • I verified that the issue exists in the latest pnpm release

pnpm version

No response

Which area(s) of pnpm are affected? (leave empty if unsure)

CLI

Link to the code that reproduces this issue or a replay of the bug

No response

Reproduction steps

  1. Install pnpm via brew.
  2. Have pnpm auto-install a node version using use-node-version or nodeVersion
  3. Try to clean up using pn env list and pnpm env remove --global 22.5.0.

Describe the Bug

mb@bia:~$ pnpm env list
  22.5.0
mb@bia:~$ pnpm env remove --global 22.5.0
ERR_PNPM_CANNOT_MANAGE_NODE  Unable to manage Node.js because pnpm was not installed using the standalone installation script

If you want to manage Node.js with pnpm, you need to remove any Node.js that was installed by other tools, then install pnpm using one of the standalone scripts that are provided on the installation page: https://pnpm.io/installation

Expected Behavior

I should be able to remove installed node versions via the cli.

Which Node.js version are you using?

22.5.1

Which operating systems have you used?

  • macOS
  • Windows
  • Linux

If your OS is a Linux based, which one it is? (Include the version if relevant)

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions