pnpm9.x 문서는 업데이트되지 않습니다.
최신 문서는최신 버전 (10.x)입니다.
버전: 9.x
pnpm dlx
Aliases:pnpx
is an alias forpnpm dlx
의존성으로 설치하지 않고 레지스트리에서 패키지를 가져와 핫로드하고 노출하는 기본 명령 바이너리를 실행합니다.
For example, to usecreate-react-app
anywhere to bootstrap a react app withoutneeding to install it under another project, you can run:
pnpm dlx create-react-app ./my-app
This will fetchcreate-react-app
from the registry and run it with the given arguments.
사용하려는 패키지의 정확한 버전을 지정할 수도 있습니다.
pnpm dlx create-react-app@next ./my-app
옵션
--package <name>
명령을 실행하기 전에 설치할 패키지를 입력합니다.
예시:
pnpm --package=@pnpm/meta-updater dlx meta-updater --help
pnpm --package=@pnpm/meta-updater@0 dlx meta-updater --help
설치를 위해 여러 패키지를 제공할 수 있습니다:
pnpm --package=yo --package=generator-webapp dlx yo webapp --skip-install
--shell-mode, -c
쉘 내부에서 명령을 실행합니다. Uses/bin/sh
on UNIX and\cmd.exe
on Windows.
예시:
pnpm --package cowsay --package lolcatjs -c dlx 'echo "hi pnpm" | cowsay | lolcatjs'
--silent, -s
실행된 명령의 결과만 출력됩니다.