move "list pending install scripts" out of approve-scripts --allow-scripts-pending · Issue #9546 · npm/cli · GitHub
Skip to content

move "list pending install scripts" out of approve-scripts --allow-scripts-pending #9546

Closed

Description

@JamieMagee

Follow-up from RFC #868 (make install scripts opt-in), tracking npm/rfcs#868 (comment).

Problem

npm approve-scripts --allow-scripts-pending (shipped in v11.16.0; --pending in the RFC text) lists packages whose install scripts aren't yet covered by allowScripts. It writes nothing. Because the command is named approve-scripts, the flag reads as "approve the pending scripts" when it only lists them. This came up as a point of confusion after the v11.16.0 release.

Current behaviour (lib/utils/allow-scripts-cmd.js):

  • npm approve-scripts --allow-scripts-pending only lists.
  • npm deny-scripts --allow-scripts-pending errors as unsupported.
  • The post-install warning sends people to npm approve-scripts --allow-scripts-pending "to review".

Proposal

Give the listing its own command so the name matches the action. Options from the thread: npm pending-scripts or npm manage-scripts. If the namespace follow-up (companion issue) lands, this becomes npm install-scripts ls.

Once the dedicated command exists, deprecate --allow-scripts-pending on approve-scripts and drop the unsupported deny-scripts path. The flag has shipped, so deprecate it rather than removing it outright.

Notes

Activity

  1. JamieMagee commented on Jun 24, 2026

    @JamieMagee
    ContributorAuthor

    Completed by #9629

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

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