pnpm outdated

Checks for outdated packages, runtimes (node, deno, bun declared in devEngines.runtime, engines.runtime, or through the runtime: / tool: protocol), package managers (pnpm, npm, yarn, bun declared in devEngines.packageManager or packageManager), Cargo crates (Cargo.toml when cargo.enabled is true), and Python packages (pyproject.toml when python.enabled is true). The check can be limited to a subset of the declared dependencies, runtimes, or package managers by providing arguments, including crate:<name> for Cargo crates and pypi:<name> for Python packages. Patterns support * wildcards, and a leading ! excludes matching names. Python selectors ignore case and treat runs of dots, underscores, and hyphens as one hyphen. Cargo selectors match both the dependency alias and the crate name.

Since v12.25.0, with cargo.enabled, pnpm outdated also lists the Rust release that a toolchain file pins, as rust, when a newer release of its channel is out. Select it with rust or leave it out with !rust. --compatible does not list it, because a pinned release moves only with pnpm update --latest.

pnpm outdated exits with code 1 when any dependency is outdated. Without a lockfile, the Current column shows the version installed in node_modules. If the dependency is not installed, it shows the lowest version allowed by the declared range. Cargo and Python checks still require their ecosystem lockfiles.

The Latest column shows the highest of the version the declared specifier resolves to and the version the latest dist-tag points to. If the installed version is a prerelease, pnpm also considers the dist-tag that points to the newest version of the same prerelease channel, such as next pointing to 3.0.0-rc.1 when 3.0.0-rc.0 is installed. pnpm update --latest does not follow prerelease channel dist-tags.

예시:

pnpm outdated
pnpm outdated "*gulp-*" @babel/core

옵션#

--recursive, -r#

하위 디렉토리에 있는 모든 패키지에서 오래된 의존성을 확인하거나 워크스페이스 내에서 모든 워크스페이스 패키지에서 오래된 의존성을 확인하십시오.

--filter <package_selector>#

필터링에 대해 자세히 알아보세요.

--global, -g#

오래된 글로벌 패키지를 나열합니다.

--long#

세부 정보를 출력합니다.

--format <format>#

  • 기본값: table
  • 유형: table, list, json

오래된 종속성을 지정한 형식으로 출력합니다.

--json#

Shorthand for --format json.

--no-table#

Shorthand for --format list.

--compatible#

package.json의 사양을 충족하는 버전만 출력합니다.

--dev, -D#

devDependencies만 확인합니다.

--prod, -P, --production#

dependencies 및 optionalDependencies만 확인합니다.

--no-optional#

optionalDependencies는 확인하지 않습니다.

--optional#

Checks optionalDependencies.

--sort-by#

출력 결과를 정렬할 순서를 지정합니다. 현재는 name 값만 허용됩니다. By default, results are sorted by the size of the version change, then by name.

--notes#

Print the release notes between the current and the latest version below each outdated package. Notes are read from registries declared with serverType: pnpr. The notes of a release that published several packages are printed once, above the notes of the versions it published. Between two stable versions, the notes of prereleases are left out. With --json, each entry gets a releaseNotes field.

--include-github-actions#

저장소의 워크플로 파일에서 참조하는 GitHub Actions의 업데이트도 확인합니다. pnpm-workspace.yaml에서 update.githubActions를 true로 설정하면 기본적으로 활성화할 수 있습니다. GitHub Actions 업데이트를 참조하세요.