pnpm runtime <cmd>

런타임을 관리합니다.

별칭: rt

Commands#

set#

지정한 버전의 런타임을 설치합니다.

pnpm runtime set <name> <version> [-g]

Without -g, the runtime is added to the current project as <name>@runtime:<version>. By default it goes to devEngines.runtime. With --save-prod, it goes to engines.runtime.

After installing, pnpm suggests running pnpm shim add <name> so that the bare command picks the project's runtime.

지원되는 런타임#

  • node - Node.js
  • deno - Deno
  • bun - Bun

정보

Installing a Node.js runtime (via pnpm runtime set node … or node@runtime:<version>) does not install the bundled npm, npx, and corepack. If you need npm, install it separately with pnpm add -g npm.

정보

The release metadata of a Node.js version is cached in the cache directory after its signature is verified. A pinned runtime whose metadata was fetched once resolves without network access.

예시#

Node.js v22를 전역으로 설치합니다:

pnpm runtime set node 22 -g

Node.js LTS 버전 설치

pnpm runtime set node lts -g

Install the newest stable release of Node.js:

pnpm runtime set node latest -g

Node.js의 시험판 버전을 설치합니다.

pnpm runtime set node nightly -g
pnpm runtime set node rc -g
pnpm runtime set node rc/22 -g
pnpm runtime set node 22.0.0-rc.4 -g

코드명을 사용하여 Node.js LTS 버전 설치:

pnpm runtime set node argon -g

Deno를 설치합니다:

pnpm runtime set deno 2 -g

Bun을 설치합니다:

pnpm runtime set bun latest -g

옵션#

--global, -g#

런타임을 전역으로 설치합니다.

--save-dev, -D#

Save the runtime to devEngines.runtime. This is the default.

--save-prod, -P#

Save the runtime to engines.runtime.