New to Claude Skills? Learn how to install them →

Plangfuse on GitHub

PNPM Upgrade Package

Free

Streamline your pnpm dependency upgrades.

by langfuse32.8k stars on langfuse/langfuse
2 views
Updated Aug 10, 2026
Get this skill

Free · Opens the source repo

What PNPM Upgrade Package does

The PNPM Upgrade Package is designed to facilitate the process of upgrading dependencies in a pnpm workspace. This skill automates the interaction with pnpm to ensure that both direct and transitive dependencies are upgraded to their target or latest versions. It incorporates checks for release age, allowing users to manage their dependencies more effectively by considering the age of releases before making upgrades. The skill is particularly useful for developers who want to maintain a clean and up-to-date dependency tree without manually tracking each package's version and compatibility.

To use this skill, you start by running a helper script that checks the release age of the specified package against your workspace's current dependencies. This initial analysis helps determine the best course of action for upgrading, whether to bump a direct dependency or to adjust transitive dependencies. The skill also provides commands for verifying the provenance of dependencies, ensuring that any upgrades do not introduce unintended changes to the project.

The skill emphasizes safety and correctness in dependency management by encouraging users to avoid manual edits to the lockfile and to use pnpm commands for any necessary updates. It includes a series of commands for preflight checks, lockfile deduplication, and final verification of the workspace's dependency graph. This structured approach minimizes the risk of breaking changes and helps maintain a stable development environment.

Overall, the PNPM Upgrade Package is ideal for developers working within a pnpm workspace who need a reliable method to manage and upgrade their dependencies efficiently while adhering to best practices in dependency management.

When to use it

Use this skill when you need to upgrade dependencies in a pnpm workspace while ensuring compatibility and stability.

When not to use it

This skill may not be suitable for projects using package managers other than pnpm or for those that require manual dependency management.

What you can build with it

Upgrading a Specific Package

Run the skill to upgrade a specific package in your pnpm workspace, ensuring all dependencies are properly managed.

Checking Release Age Before Upgrading

Use the skill to check the release age of a package to decide whether to upgrade based on stability and compatibility.

Verifying Dependency Changes

After an upgrade, utilize the skill to verify that only the intended versions remain in your workspace.

How to install PNPM Upgrade Package

View source

1. Install with the skills CLI

npx skills add langfuse/langfuse/pnpm-upgrade-package --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by langfuse

PNPM Upgrade Package

Use this skill for interactive dependency bumps in Langfuse.

Read Order

  • Use this SKILL.md for the end-to-end workflow.
  • Run the main helper once at the start of the upgrade: node .agents/skills/pnpm-upgrade-package/scripts/check-release-age-window.mjs <package> [targetVersion]

Apply This Skill

  • Ask for the package name if the user did not provide one.
  • Ask for the target version if the user did not provide one.
  • Run the main helper once as the first analysis step and use that single output for scope, exclusion decisions, and the final bump.
  • If the target package is not directly declared anywhere, run pnpm why -r <package> to find which direct dependency brings it in, then inspect whether the current top-level parent already allows the requested transitive version via its dependency range.
  • If the current parent range already covers the requested transitive version, prefer a lockfile refresh / reinstall path over bumping the parent manifest.
  • If the current parent range does not cover the requested transitive version, upgrade that parent dependency instead of adding the target package directly unless the user explicitly wants that.
  • If pnpm will not move an already-allowed transitive version, a scoped overrides entry in pnpm-workspace.yaml may be used as a temporary resolution tool. Before finishing, prove whether the override is still required: remove it, run pnpm install, then run pnpm dedupe. Inspect the diff after each generated change. If the target version remains without the override, do not keep the override; keep or restore it only when pnpm reverts or drifts from the requested version without it.
  • Never manually edit pnpm-lock.yaml; regenerate lockfile changes with pnpm commands only. If a lockfile-only refresh causes unrelated churn, adjust the pnpm command and rerun instead of patching the lockfile by hand.
  • After fixing or upgrading a package, run pnpm dedupe. Always inspect the diff after dedupe and revert that generated attempt if it introduces unrelated churn.
  • Resolve the registry latest version, but do not silently upgrade to latest unless the user asked for latest.
  • Compare the target version with the latest version installable under the current minimumReleaseAge window.
  • Before generating lockfile changes, run pnpm install --dry-run --ignore-scripts to catch resolver and policy failures without writing pnpm-lock.yaml or node_modules.
  • Inspect any dry-run "would make changes" output as baseline resolver drift before deciding which write command is safe.
  • Ask before adding minimumReleaseAgeExclude entries for the target package, exact dependency companions from dependencies or optionalDependencies, or locally installed exact peer dependencies.
  • Finish with pnpm why -r <package> to confirm that only the intended version remains in the workspace.
  • In the final response, include a copy-pasteable human commit command using the resolved package name and target version. Use a branch-safe package slug for scoped packages, but keep the exact package name in the commit message: git switch -C deps/bump-<package-slug>-to-<version> && git commit -m "chore(deps): bump <package> to <version>" --no-verify

Quick Commands

  • Analysis pass: node .agents/skills/pnpm-upgrade-package/scripts/check-release-age-window.mjs <package> <targetVersion>
  • Transitive provenance / final graph verification: pnpm why -r <package>
  • Inspect a current parent manifest on the registry: npm view <parent>@<installedVersion> dependencies peerDependencies optionalDependencies --json
  • Preflight resolver/policy check: pnpm install --dry-run --ignore-scripts
  • Optional lockfile cleanup: pnpm dedupe
  • Bump in the root workspace: pnpm -w up <package>@<version>
  • Bump in one workspace: pnpm --filter web up <package>@<version>
  • Bump everywhere that should move together: pnpm -r up <package>@<version>
  • Verify temporary override removal: remove the override, then run pnpm install and pnpm dedupe
  • Human commit helper: git switch -C deps/bump-<package-slug>-to-<version> && git commit -m "chore(deps): bump <package> to <version>" --no-verify

Frequently asked questions about PNPM Upgrade Package

Similar skills