npm-upgrade

Audit and upgrade npm packages across Node.js projects with lockfile support.

25|Updated Feb 22, 2026
One-click install
npx skills add https://github.com/peterfox/agent-skills --skill npm-upgrade
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: npm-upgrade
Source: https://github.com/peterfox/agent-skills/tree/main/npm-upgrade
Command: npx skills add https://github.com/peterfox/agent-skills --skill npm-upgrade

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

Identify and execute secure npm package upgrades while auditing vulnerabilities.

Core Features & Use Cases

  • Detects the appropriate package manager by lockfile and outlines an upgrade plan across npm, yarn, and pnpm.
  • Guides through the upgrade workflow: audit, fix, outdated, explain, update, test, and re-audit.
  • Provides merge-conflict resolution tooling guidance using scripts/diff_lock.py and references to related workflows.

Quick Start

Begin by running an npm audit to identify vulnerabilities, then follow the documented upgrade workflow to safely update dependencies and re-audit.

Frequently Asked Questions about npm-upgrade

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I securely upgrade npm dependencies and fix vulnerabilities in Node.js?

Secure npm package upgrades are executed by running an audit to identify vulnerabilities, auto-fixing critical issues, updating outdated packages, running tests, and re-auditing to ensure zero vulnerabilities remain.

What is the best workflow for resolving npm dependency conflicts during upgrades?

The upgrade workflow handles dependency conflicts by auditing, auto-fixing, identifying outdated packages, explaining blockers, updating, testing, and re-auditing to ensure secure and stable dependency resolution.

Can I use this npm audit and upgrade workflow with Yarn or pnpm?

Yes, the workflow detects the appropriate package manager by analyzing the lockfile and outlines a tailored upgrade plan across npm, Yarn, and pnpm environments.

How do I resolve package-lock.json merge conflicts after upgrading dependencies?

Lockfile merge conflicts are resolved using the provided scripts/diff_lock.py tooling guidance, which helps diff and merge lockfile changes during dependency upgrades.

Why should I follow a guided workflow instead of just running npm update?

A guided workflow ensures secure upgrades by auditing vulnerabilities, explaining blockers, and re-auditing after updates, whereas a simple npm update may silently introduce CVEs or break dependencies.