Skip to content
This repository was archived by the owner on Aug 11, 2022. It is now read-only.
This repository was archived by the owner on Aug 11, 2022. It is now read-only.

npm prune is removing packages installed using git #19356

@jsynowiec

Description

@jsynowiec

I'm opening this issue because:

  • npm is crashing.
  • npm is producing an incorrect install.
  • npm is doing something I don't understand.
  • Other (see below for feature requests):

What's going wrong?

Packages present under the dependencies in the package.json file that were installed using git/github package links, e.g. github:npm/npm#some-tag are being uninstalled when npm prune is executed.

How can the CLI team reproduce the problem?

  1. Install a package using standard syntax, save it as a dependency,
  2. Install another a package using git+<proto>:, git:// or github: format, save it as dependency.
  3. Run npm prune

Expected: Second package is present.
Actual: Second package is missing.

supporting information:

  • npm -v prints: 5.6.0
  • node -v prints: 8.9.1
  • npm config get registry prints: https://registry.npmjs.org/
  • Windows, OS X/macOS, or Linux?: macOS
  • Network issues (unrelated)

additional information:

Workaround - When a tarball url is used, the package is not removed on prune.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions