dependency-changes
Skill98 starsChanged 2 months agoMITView on GitHub
Adding, upgrading, or removing dependencies — justification bar, registry-verified versions, changelog and pinned-constraint archaeology, matching package-manager and lockfile hygiene, one bump at a time, gates after. Use when adding, bumping, removing, or auditing a package; before editing package.json, pyproject.toml, Cargo.toml, go.mod, or any lockfile; on security advisories, audit/Dependabot alerts, deprecation or peer-dependency warnings, version-mismatch errors, or "update everything" requests.
In this repository38 other files it gives its agents.
- ambiguity-commitSkill
- api-surface-careSkill
- calibrated-recommendationSkill
- codebase-orientationSkill
- concurrency-reasoningSkill
- config-and-flagsSkill
- context-checkpointSkill
- cross-platform-careSkill
- data-loss-guardSkill
- data-migration-safetySkill
- docs-as-contractSkill
- edge-case-sweepSkill
- environment-firstSkill
- error-message-qualitySkill
- escalate-vs-decideSkill
- estimation-and-scopingSkill
- explain-at-the-right-levelSkill
- generalize-the-correctionSkill
- git-hygieneSkill
- incident-diagnosisSkill
- leave-no-messSkill
- llm-app-codeSkill
- numerical-careSkill
- performance-investigationSkill
- perf-sanitySkill
- question-vs-taskSkill
- resource-lifecycleSkill
- reviewing-a-changeSkill
- root-cause-debuggingSkill
- security-reflexesSkill
- stop-thrashingSkill
- subagent-fanoutSkill
- surgical-refactoringSkill
- task-decompositionSkill
- test-designSkill
- untrusted-content-guardSkill
- verify-ui-visuallySkill
- workmanshipSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 30
Read the lockfile diff: it should touch what you expect.
- Distinctive: line 31
Commit lockfile and manifest together, and (unless asked otherwise) separately from feature code.
≈ “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.
Files
Dependency Changes
Weak dependency work types a version number from memory, runs whichever install command comes to mind, and declares success when the install exits 0. Strong dependency work queries the registry, uses the project's own package manager, changes one thing, runs the gates, and reads the lockfile diff before committing.
Adding a dependency
- Clear the justification bar: does the stdlib do it? Does an existing dependency (read the manifest — the codebase often already carries a lib covering 90%)? Is it small enough to write inline (a 20-line util beats a package)? Only then add.
- Vet it: last release date, open-issue triage, download count, license, install footprint and transitive count (
npm info,pip show,cargo tree, or the equivalent). 40 transitive deps for one function is a bad trade. - Use the project's package manager exactly: identify it from the lockfile present (
pnpm-lock.yaml,yarn.lock,package-lock.json,uv.lock,poetry.lock,Cargo.lock, ...) and use the matching tool. Never create a second lockfile kind; never hand-edit a lockfile; respect workspace/catalog conventions in monorepos. - Pin the way neighbors pin: exact vs caret vs range — copy the manifest's existing style.
Upgrading
- Never write a version from memory. Query the registry for the current version (
npm view <pkg> version,pip index versions <pkg>,cargo search <pkg>,go list -m -versions <mod>) and read the currently installed version from the lockfile, not the manifest range. Paste both in your report. - Read the changelog between installed and target — the BREAKING sections and migration guides. For a major bump, budget for API changes instead of discovering them via type errors.
- Check for pinned-constraint reasons before bumping. A dependency held at an old major is often deliberate. Search CLAUDE.md, README, comments, and
git log -S<pkg>for the package name. "Upgrade everything" does not authorize breaking a documented pin. - Check engine and peer constraints: the target's required runtime version and peer ranges against what the project runs. A peer warning in the install output is an error that has not happened yet — report it, do not scroll past it.
- One bump at a time (or one tightly coupled group, e.g. a framework and its plugins). A 15-package bump that breaks the build is unbisectable.
- Security advisories: take the smallest version delta that clears the advisory; check whether the vulnerable path is reachable in this codebase when judging urgency.
After ANY dependency change
- Full install with the project's tool, then the full gate suite: build/typecheck, lint, tests.
- Exercise the features that use the changed package at runtime — type-compatible is not behavior-compatible (defaults change, peer behavior shifts).
- Read the lockfile diff: it should touch what you expect. A one-package bump that rewrites 500 lockfile lines gets explained before it gets committed.
- Commit lockfile and manifest together, and (unless asked otherwise) separately from feature code.
Removing
Grep for every import/require AND every string reference — plugins, rc files, build configs, and CI reference packages by name. Remove, reinstall, run gates. Dead dependencies are worth removing when noticed, as their own commit.
Surface rather than push through
Typosquat-adjacent names, install scripts doing surprising work, an upgrade that forces a cascade (runtime version, framework major), a license change, or a registry version that differs from what the user asked for. These are decisions for the user, with your recommendation attached.
Report
Include: package, installed → target version with the registry query that produced it, the changelog items that affect this codebase, install warnings, gate results, what you exercised at runtime, and the lockfile diff size.
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
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.

