Dependency Upgrade Template

This template provides a systematic approach to upgrading dependencies safely while minimizing breaking changes and ensuring application stability. It covers assessment, testing, and rollback strategies.

Sample Prompt

Plan a major dependency upgrade for a Node.js application:
- Audit current dependencies for security vulnerabilities
- Identify breaking changes in major version upgrades
- Create upgrade strategy with incremental updates
- Test compatibility with existing codebase
- Update related configuration and documentation
- Plan rollback procedures in case of issues

What This Template Covers

  • Dependency auditing for security vulnerabilities and outdated packages
  • Breaking change assessment and compatibility analysis
  • Upgrade strategy planning with incremental and risk-based approaches
  • Testing procedures to validate functionality after upgrades
  • Rollback planning and contingency procedures for failed upgrades
  • Documentation updates and team communication strategies

Best Practices

  1. Audit dependencies regularly for security and maintenance issues
  2. Test upgrades thoroughly in development and staging environments
  3. Upgrade incrementally rather than jumping multiple major versions
  4. Read release notes carefully to understand breaking changes
  5. Maintain rollback capabilities with version pinning and backup strategies
  6. Update documentation and configuration files as needed
  7. Communicate changes to team members and stakeholders
  8. Monitor post-upgrade for issues and performance impacts

When to Use This Template

  • Performing regular dependency maintenance and updates
  • Addressing security vulnerabilities in dependencies
  • Upgrading to major new versions with breaking changes
  • Modernizing legacy applications with outdated dependencies
  • Establishing dependency management processes for development teams

The Script

peep dependency-upgrade