cpa03

dependency-audit

Audit npm dependencies for security vulnerabilities, outdated packages, and license compliance.

cpa03 0 Actualitzat fa 8 mesos
GitHub

Instal·la

npx skillscat add cpa03/blueprintify/opencode-skill-dependency-audit

Instal·la des del registre de SkillsCat.

SKILL.md

Dependency Audit Skill

Comprehensive npm dependency security and health check.

Security Audit

  1. Run npm audit:

    npm audit
  2. For detailed JSON output:

    npm audit --json
  3. Fix automatically if safe:

    npm audit fix
  4. For breaking changes (be careful):

    npm audit fix --force

Outdated Packages

  1. Check for outdated:

    npm outdated
  2. Update specific package:

    npm update <package-name>
  3. Update to latest (major versions):

    npx npm-check-updates -u
    npm install

License Check

  1. List all licenses:

    npx license-checker --summary
  2. Check for problematic licenses:

    npx license-checker --onlyAllow "MIT;Apache-2.0;BSD-2-Clause;BSD-3-Clause;ISC"

Bundle Analysis

  1. Analyze bundle size:

    npx source-map-explorer dist/**/*.js
  2. Find duplicate dependencies:

    npx npm-dedupe

Output Report

## Dependency Audit Report

### Security

- Critical: X
- High: X
- Medium: X
- Low: X

### Outdated Packages

| Package | Current | Wanted | Latest |
| ------- | ------- | ------ | ------ |
| ...     | ...     | ...    | ...    |

### Actions Required

1. [Action with priority]
2. [Action with priority]