agentleFS
yu-iskwyu-iskw/coding-agent-fabric/.claude/skills/node-upgrade/SKILL.md

node-upgrade

Skill1 starsChanged 9 months agoApache-2.0View on GitHub

Safely upgrade Node.js dependencies in pnpm workspaces. Use when asked to "upgrade dependencies", "update packages", "check for updates", or fix version mismatches.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

15 rules. About 0 are common, 5 are distinctive, and 10 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 10

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Before making any changes, verify the current state of the project:

    line 12
  2. Very specific:

    Run an audit: pnpm audit.

    line 15
  3. Very specific:

    Run the test suite: pnpm test.

    line 16
  4. Distinctive:

    Use this when the user specifies a package or a small set of packages.

    line 27
  5. Very specific:

    Upgrade: Run the targeted upgrade command (e.g., pnpm update <package>).

    line 29
  6. Very specific:

    Verify: Check package.json to ensure the version has been updated.

    line 30
  7. Distinctive:

    Use this for general dependency maintenance.

    line 34
  8. Very specific:

    Upgrade: Run the full upgrade command (e.g., pnpm update).

    line 36
  9. Distinctive:

    After the upgrade, ensure the project remains stable by delegating to the project verifier:

    line 41
  10. Very specific:

    Invoke Verifier: Use the verifier subagent (../../agents/verifier.md) to run the full build, lint, and test cycle.

    line 43
  11. Very specific:

    Handle Failure: If the verifier reports persistent issues it cannot fix, analyze the breaking changes and apply manual fixes or roll back.

    line 44
  12. Very specific:

    Commit: Create a commit with the updated package.json and lockfile.

    line 49
  13. Very specific:

    Cleanup: Remove backup files: rm *.bak.

    line 51
  14. Distinctive:

    If validation fails and cannot be easily fixed:

    line 55
  15. Very specific:

    Re-install: Run pnpm install to restore the environment.

    line 58

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Safe Node.js Dependency Upgrade

This skill provides a structured process for safely upgrading Node.js dependencies, ensuring project stability through pre-upgrade health checks and post-upgrade validation.

1. Preparation & Health Check

Before making any changes, verify the current state of the project:

  1. Baseline Health Check:
    • Run an audit: pnpm audit.
    • Run the test suite: pnpm test.
    • Constraint: If the baseline tests fail, resolve those issues before proceeding with upgrades.
  2. Backup:
    • Backup package.json and the lockfile: cp pnpm-lock.yaml pnpm-lock.yaml.bak.

2. Upgrade Execution

Choose the appropriate upgrade path based on the user's request. Refer to ../common-references/pnpm-commands.md for pnpm-specific commands.

Targeted Upgrade (Recommended)

Use this when the user specifies a package or a small set of packages.

  1. Upgrade: Run the targeted upgrade command (e.g., pnpm update <package>).
  2. Verify: Check package.json to ensure the version has been updated.

Full Upgrade (Maintenance)

Use this for general dependency maintenance.

  1. Upgrade: Run the full upgrade command (e.g., pnpm update).
  2. Check for Breaking Changes: Review the lockfile changes and check for major version bumps.

3. Validation & Verification

After the upgrade, ensure the project remains stable by delegating to the project verifier:

  1. Invoke Verifier: Use the verifier subagent (../../agents/verifier.md) to run the full build, lint, and test cycle.
  2. Handle Failure: If the verifier reports persistent issues it cannot fix, analyze the breaking changes and apply manual fixes or roll back.
  3. Final Audit: Once the verifier passes, run pnpm audit again to ensure no new vulnerabilities were introduced.

4. Finalization

  1. Commit: Create a commit with the updated package.json and lockfile.
    • Message Suggestion: chore(deps): upgrade dependencies
  2. Cleanup: Remove backup files: rm *.bak.

Rollback Plan

If validation fails and cannot be easily fixed:

  1. Restore: mv package.json.bak package.json and mv <lockfile>.bak <lockfile>.
  2. Re-install: Run pnpm install to restore the environment.
  3. Report: Notify the user of the failure and the reasons (e.g., specific breaking changes).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.