Skip to content

feat(development-productivity): add audit-dependencies skill#459

Open
wkoutre wants to merge 2 commits intonextfrom
feat/add-skill-audit-dependencies
Open

feat(development-productivity): add audit-dependencies skill#459
wkoutre wants to merge 2 commits intonextfrom
feat/add-skill-audit-dependencies

Conversation

@wkoutre
Copy link
Copy Markdown
Contributor

@wkoutre wkoutre commented Apr 14, 2026

What gap this fills

The development-productivity plugin had no dependency health tooling. Developers had to manually remember to run npm audit before releases, and there was no structured workflow for assessing outdated packages. This skill fills that gap.

How it was identified

During gap analysis of the plugin ecosystem, the dependency lifecycle phase was absent — no tooling for auditing CVEs, identifying stale packages, or applying safe updates in a structured way.

Example usage scenarios

  • "audit my dependencies" — full audit, report only
  • "run npm audit and fix what's safe" — audit + auto-apply safe patches
  • "check for vulnerable packages --scope security" — CVEs only
  • "dependency health check --fix --minor" — audit + update to latest minor
  • "show me what would change --dry" — dry-run view of planned updates

Changes

  • Adds packages/plugins/development-productivity/skills/audit-dependencies/SKILL.md
  • Updates plugin.json (version 2.2.02.3.0, skill registered)
  • Updates CLAUDE.md and README.md with new skill documentation

Test plan

  • Skill triggers on "audit my dependencies", "run npm audit", "check for vulnerable packages"
  • Skill correctly detects npm / yarn / pnpm / bun based on lockfile
  • --fix applies only patch updates
  • --fix --minor also applies minor updates
  • --scope security omits outdated-only output
  • --dry shows planned changes without applying them
  • Report format matches documented structure
  • Plugin validates: node scripts/validate-plugin.cjs packages/plugins/development-productivity
  • Markdown lints clean: npm exec markdownlint-cli2 -- "packages/plugins/development-productivity/**/*.md"
AI-Generated Description

Summary

  • Adds audit-dependencies skill to the development-productivity plugin for auditing project dependencies for security vulnerabilities and outdated packages
  • Supports all major package managers (npm, yarn, pnpm, bun) via lockfile detection
  • Provides structured reporting with severity-based prioritization and optional safe auto-updates

Changes

File Change
packages/plugins/development-productivity/skills/audit-dependencies/SKILL.md New skill definition with full audit workflow, package manager detection, options (--fix, --minor, --scope, --dry), and structured report format
packages/plugins/development-productivity/.claude-plugin/plugin.json Register audit-dependencies in skills array; bump version 2.3.0 → 2.4.0
packages/plugins/development-productivity/CLAUDE.md Add skill to component list and file structure
packages/plugins/development-productivity/README.md Add skill to skills table and example usage section
CLAUDE.md (root) Update development-productivity version in plugin version table (2.2.0 → 2.4.0)

Context

The development-productivity plugin had no dependency health tooling. This skill fills the dependency lifecycle gap by providing a structured workflow for auditing CVEs, identifying stale packages, and applying safe updates — without requiring developers to manually remember audit commands or parse raw JSON output.

Test plan

  • Skill triggers on "audit my dependencies", "run npm audit", "check for vulnerable packages"
  • Correctly detects npm / yarn / pnpm / bun based on lockfile
  • --fix applies only patch-level updates by default
  • --fix --minor also applies minor version updates
  • --scope security limits output to CVEs only
  • --dry shows planned changes without applying them
  • Report format matches documented structure
  • Plugin validates: node scripts/validate-plugin.cjs packages/plugins/development-productivity

@wkoutre wkoutre requested a review from a team as a code owner April 14, 2026 11:01
@vercel
Copy link
Copy Markdown

vercel bot commented Apr 14, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ai-toolkit-slack-oauth-backend Ready Ready Preview, Comment Apr 14, 2026 4:01pm

Request Review

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 14, 2026

🤖 Claude Code Review

Review complete

Re-Review: Add audit-dependencies skill to development-productivity plugin

Summary

This PR adds a new audit-dependencies skill that audits project dependencies for security vulnerabilities and outdated packages. The previous review raised two issues — both have been addressed in the current revision.

Previous Issues — Resolved

  1. Yarn Berry detection — Step 1 now includes a yarn --version check and documents both Classic (v1) and Berry (v2+) audit commands in the lockfile table.
  2. Patch-only mode — Step 5 now clearly separates behavior for --fix alone (only npm audit fix) vs --fix --minor (npm audit fix + npm update), with explicit warnings about caret range behavior.

Current Review

No blocking issues found. The skill is well-structured with clear steps, a useful options table, and a good report template. Version bump from 2.3.0 → 2.4.0 is correct (new skill = minor bump). All documentation files (plugin.json, CLAUDE.md, README.md, root CLAUDE.md) are updated consistently.

Minor observation (non-blocking): Step 2's code examples only show npm, yarn (classic), and pnpm audit commands but omit yarn npm audit --json for Berry and bun audit. Step 1's table covers all variants, so this is just a completeness gap in the examples — not a functional issue since the AI agent will use the table from Step 1.


💡 Want a fresh review? Add a comment containing @request-claude-review to trigger a new review at any time.

Copy link
Copy Markdown
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📋 Review verdict: REQUEST_CHANGES

👆 The main review comment above is the source of truth for this PR review. It is automatically updated on each review cycle, so always refer to it for the most current feedback.

This formal review submission is for the verdict only.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 827cb4ccd3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +113 to +114
# npm — also update within semver range
npm update 2>/dev/null
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Honor patch-only mode when applying npm fixes

The --fix option is documented as patch-only unless --minor is set, but Step 5 unconditionally includes npm update. npm's own update behavior is to install the highest version that satisfies the declared semver range (for example, caret ranges can move to newer minor releases), so this workflow can apply minor upgrades even when --minor was not requested. That breaks the promised safety boundary and can introduce unintended runtime changes during a supposedly patch-only remediation.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. Step 5 now distinguishes between patch-only and minor modes. When --fix is used without --minor, only npm audit fix is run (which is restricted to patch-level fixes by npm). npm update is now gated behind the --minor flag, with an explicit warning in the code comment explaining that npm update can advance caret ranges to newer minor releases.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed fixed. Step 5 now properly gates npm update behind the --minor flag and documents the distinction between patch-only and minor update modes. The warning comment about caret range behavior is a nice touch.

| Lockfile | Package Manager | Audit Command | Outdated Command |
| ----------------- | --------------- | -------------------------- | ------------------------- |
| `package-lock.json` | npm | `npm audit --json` | `npm outdated --json` |
| `yarn.lock` | yarn | `yarn audit --json` | `yarn outdated --json` |
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Detect Yarn Berry before choosing audit command

Step 1 maps any yarn.lock project to yarn audit --json, but Yarn 2+ (Berry) uses yarn npm audit instead (also acknowledged in the Notes section). Without a version check, Berry repositories will follow this table and invoke the wrong command, which prevents the skill from producing the expected audit report in a common Yarn setup.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. The skill now detects the Yarn version via yarn --version before choosing the audit command: Classic v1 uses yarn audit --json, while Berry v2+ uses yarn npm audit --json. The detection step is documented in the updated Step 1 table.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed fixed. Step 1 now includes yarn --version detection and the table has separate rows for Classic v1 and Berry v2+ with the correct audit commands.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 14, 2026

📚 Documentation Check ✅

Verdict: Passed

All required documentation is present: plugin version bumped (2.3.0 → 2.4.0), CLAUDE.md updated, README.md updated, and new SKILL.md created.


PR #459 Documentation Review

This PR adds the audit-dependencies skill to the development-productivity plugin. All required documentation updates are present:

  • Plugin version: Bumped from 2.3.02.4.0 in plugin.json
  • Root CLAUDE.md: Version table updated to 2.4.0
  • Plugin CLAUDE.md: New skill added to skills list and file structure tree ✅
  • Plugin README.md: New skill added to skills table and example triggers ✅
  • SKILL.md: New file created with full skill documentation ✅

Minor observation: The root CLAUDE.md previously showed 2.2.0 for development-productivity while plugin.json was at 2.3.0 — a pre-existing one-version lag. This PR corrects both to 2.4.0, resolving the discrepancy.

No blocking issues found.

✨ No Documentation Updates Needed

All documentation appears to be up to date with the code changes.


🤖 Generated by Claude Documentation Validator | Mode: suggest

- Bump development-productivity plugin version from 2.3.0 to 2.4.0
- Update CLAUDE.md version table to reflect 2.4.0
- Fix Yarn Berry detection: check yarn --version before picking audit command (yarn audit --json for v1, yarn npm audit --json for v2+)
- Fix patch-only mode: do not run npm update unconditionally; gate it behind --minor flag to prevent unintended minor version upgrades

Resolved comments from: github-actions[bot]
PR: #459
@github-actions github-actions bot dismissed their stale review April 14, 2026 16:02

Superseded by new review after PR update

Copy link
Copy Markdown
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📋 Review verdict: APPROVE

👆 The main review comment above is the source of truth for this PR review. It is automatically updated on each review cycle, so always refer to it for the most current feedback.

This formal review submission is for the verdict only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant