本文へスキップ
Skillpedia
一般的なプログラミング48k · #4370

dependency-upgrade

できること

プロジェクトにある、ソフトウェアライブラリ(依存関係)のメジャーバージョンを更新する手助けをします。新しいバージョン同士が互いに問題なく動作するかを確認し、安全に更新を行う方法を提案します。

使う場面

  • ✓主要なライブラリを新しいメジャーバージョンに更新するとき。
  • ✓プロジェクトのライブラリがうまく連携して動くことを確認したいとき。
  • ✓古いパッケージのセキュリティアップデートを計画するとき。

スキルのリンク

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/dependency-upgrade/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/dependency-upgrade/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“Reactをバージョン16から18にアップグレードするには、どうすれば安全に行えますか?”

毎週5つの新しいスキル。1分で読めます。

仕組み

AIはプロジェクトの依存関係を分析し、互換性マトリクスを使ってそれらの互換性を確認します。そして、各ステップでテストを行いながら進める段階的なアップグレード計画を提案します。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

Supporting material availability

This catalog copy contains the inline guidance below, but does not include the following supporting paths. They are external prerequisites, not bundled files:

  • <support-root>/references/semver.md
  • <support-root>/references/compatibility-matrix.md
  • <support-root>/references/staged-upgrades.md
  • <support-root>/references/testing-strategy.md
  • <support-root>/assets/upgrade-checklist.md
  • <support-root>/assets/compatibility-matrix.csv
  • <support-root>/scripts/audit-dependencies.sh

Ask for the original supporting material or an existing installation before using a step that depends on these paths; this catalog does not identify a verified download source for them. Resolve each path relative to that installation, inspect its contents, and verify any applicable license and execution prerequisites. Do not run a command or claim a referenced procedure was followed until its required file exists. Do not fabricate the missing scripts or treat an unrelated file with the same name as equivalent. Independent steps fully documented here can proceed within the user’s authorized scope; report any dependent step as unavailable.

Dependency Upgrade

Master major dependency version upgrades, compatibility analysis, staged upgrade strategies, and comprehensive testing approaches.

Do not use this skill when

  • The task is unrelated to dependency upgrade
  • You need a different domain or tool outside this scope

Instructions

  • Clarify goals, constraints, and required inputs.
  • Apply relevant best practices and validate outcomes.
  • Provide actionable steps and verification.

Use this skill when

  • Upgrading major framework versions
  • Updating security-vulnerable dependencies
  • Modernizing legacy dependencies
  • Resolving dependency conflicts
  • Planning incremental upgrade paths
  • Testing compatibility matrices
  • Automating dependency updates

Semantic Versioning Review

MAJOR.MINOR.PATCH (e.g., 2.3.1)

MAJOR: Breaking changes
MINOR: New features, backward compatible
PATCH: Bug fixes, backward compatible

^2.3.1 = >=2.3.1 <3.0.0 (minor updates)
~2.3.1 = >=2.3.1 <2.4.0 (patch updates)
2.3.1 = exact version

Dependency Analysis

Audit Dependencies

# npm
npm outdated
npm audit
npm audit fix

# yarn
yarn outdated
yarn audit

# Check for major updates
npx npm-check-updates
npx npm-check-updates -u  # Update package.json

Analyze Dependency Tree

# See why a package is installed
npm ls package-name
yarn why package-name

# Find duplicate packages
npm dedupe
yarn dedupe

# Visualize dependencies
npx madge --image graph.png src/

Compatibility Matrix

// compatibility-matrix.js
const compatibilityMatrix = {
  'react': {
    '16.x': {
      'react-dom': '^16.0.0',
      'react-router-dom': '^5.0.0',
      '@testing-library/react': '^11.0.0'
    },
    '17.x': {
      'react-dom': '^17.0.0',
      'react-router-dom': '^5.0.0 || ^6.0.0',
      '@testing-library/react': '^12.0.0'
    },
    '18.x': {
      'react-dom': '^18.0.0',
      'react-router-dom': '^6.0.0',
      '@testing-library/react': '^13.0.0'
    }
  }
};

function checkCompatibility(packages) {
  // Validate package versions against matrix
}

Staged Upgrade Strategy

Phase 1: Planning

# 1. Identify current versions
npm list --depth=0

# 2. Check for breaking changes
# Read CHANGELOG.md and MIGRATION.md

# 3. Create upgrade plan
echo "Upgrade order:
1. TypeScript
2. React
3. React Router
4. Testing libraries
5. Build tools" > UPGRADE_PLAN.md

Phase 2: Incremental Updates

# Don't upgrade everything at once!

# Step 1: Update TypeScript
npm install typescript@latest

# Test
npm run test
npm run build

# Step 2: Update React (one major version at a time)
npm install react@17 react-dom@17

# Test again
npm run test

# Step 3: Continue with other packages
npm install react-router-dom@6

# And so on...

Phase 3: Validation

// tests/compatibility.test.js
describe('Dependency Compatibility', () => {
  it('should have compatible React versions', () => {
    const reactVersion = require('react/package.json').version;
    const reactDomVersion = require('react-dom/package.json').version;

    expect(reactVersion).toBe(reactDomVersion);
  });

  it('should not have peer dependency warnings', () => {
    // Run npm ls and check for warnings
  });
});

Breaking Change Handling

Identifying Breaking Changes

…

よくある質問

セマンティックバージョニング(SemVer)とは何ですか?

ソフトウェアのバージョン番号の変わり方に関するルールです。MAJOR.MINOR.PATCH の形式で、MAJOR は互換性のない変更、MINOR は後方互換性のある機能追加、PATCH はバグ修正を示します。

「破壊的変更(breaking changes)」とは何ですか?

新しいソフトウェアのバージョンで行われた変更のうち、以前のバージョンを使っているプロジェクトが動かなくなる可能性があるものです。通常はメジャーバージョンの更新で起こります。

なぜ段階的にアップグレードするのですか?

一度にすべてをアップグレードすると、問題が起きたときにリスクが高く、原因の特定も難しくなります。段階的に行えば、変更を一つずつテストできるため、問題を見つけて修正しやすくなります。

詳細

作者による元の説明

Master major dependency version upgrades, compatibility analysis, staged upgrade strategies, and comprehensive testing approaches.

repo: sickn33/agentic-awesome-skills

人気

GitHubのスター
48k
ランキング
#4370
ライセンス
MIT
更新日
2026/10/15

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル