LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

pnpx

Execute packages without installing them

TLDR

Run package without installing
$ pnpx [package] [args]
copy
Run specific version
$ pnpx [package]@[version] [args]
copy
Run with package name different from command
$ pnpx --package [package] [command]
copy
Install multiple packages and run a command
$ pnpx --package [pkg1] --package [pkg2] [command]
copy

SYNOPSIS

pnpx [options] package [args]

DESCRIPTION

pnpx executes npm packages without permanently installing them, similar to npx. It downloads the package to a temporary location, runs the specified command, and cleans up afterward. This is a deprecated alias for pnpm dlx; prefer using pnpm dlx directly.Use --package to specify a package name when the executable name differs from the package name. The @version suffix allows running a specific package version. Packages executed by pnpx are allowed to run postinstall scripts by default.

PARAMETERS

PACKAGE

Package to execute.
--package PKG
Package to install (if different from command). Can be specified multiple times.

CAVEATS

pnpx is deprecated in favor of pnpm dlx. Requires pnpm installed. The command runs inside a shell (/bin/sh on Unix, cmd.exe on Windows).

SEE ALSO

pnpm(1), npx(1), yarn-dlx(1)

Copied to clipboard
Kai