Token导航 LogoToken导航

Agent Skill · 研究检索

code-quality-audit(代码质量审计)

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查。它适合让 Agent 梳理敏感配置、检查依赖风险、分析鉴权逻辑或生成安全复核清单。使用时不能把工具输出直接当最终结论,涉及密钥、令牌、用户数据或生产系统时,应先确认最小权限、脱敏方式和操作边界。

code-quality-audit 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证信息还不明确,第三方扫描有提醒项,按安装量在研究检索类的 73,675 个 Skill 里排第 54,843。

总安装 494周安装 20GitHub Stars 23下载 155核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:code-quality-audit(代码质量审计)
来源仓库:https://github.com/camoa/claude-skills
仓库路径:skills/code-quality-audit
安装命令:
npx skills add https://github.com/camoa/claude-skills --skill code-quality-audit
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/camoa/claude-skills --skill code-quality-audit

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

code-quality-audit 提供 Drupal 和 Next.js 项目的质量与安全审计功能。适用于代码规范检查、依赖风险识别和安全漏洞扫描等场景。支持多种快速命令调用,可生成结构化审计报告供人工复核。涉及生产环境时需谨慎操作,建议先在小范围测试后再执行完整扫描。

适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

来源仓库内路径:skills/code-quality-audit

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/camoa/claude-skills --skill code-quality-audit;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

code-quality-audit 怎么安装?

在终端执行 npx skills add https://github.com/camoa/claude-skills --skill code-quality-audit。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

code-quality-audit 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

code-quality-audit 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

code-quality-audit 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

code-quality-audit 用的人多吗?

公开数据是累计安装 494 次,近一周安装 20 次,下载 155 次,GitHub 23 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

code-quality-audit 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
code-quality-audit

代码质量审计 · 本页

49423接触敏感数据未明确有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Code Quality Audit

Run quality and security audits for Drupal and Next.js projects with consistent tooling and reporting.

Quick Commands

For direct access, use these commands:

  • /code-quality:setup - First-time setup wizard (install and configure tools)
  • /code-quality:audit - Run full audit (all 22 operations)
  • /code-quality:coverage - Check test coverage
  • /code-quality:security - Security scan (10 layers for Drupal, 7 for Next.js)
  • /code-quality:lint - Code standards check
  • /code-quality:solid - Architecture and SOLID principles check
  • /code-quality:dry - Find code duplication
  • /code-quality:tdd - Start TDD workflow (test watcher mode)
  • /code-quality:review - Rubric-scored code review (/50 scale with quality gate)
  • /code-quality:generate-review-md - Generate REVIEW.md for Claude Code's managed Code Review
  • /code-quality:architecture-debate - Architecture debate (Pragmatist + Purist + Maintainer)

For conversational workflows, continue reading...

Note — Claude Code's built-in /simplify: Claude Code ships a built-in /simplify skill for quick single-pass code review. /code-quality:review is different: it runs automated tools (PHPStan/ESLint), scores across 10 rubric categories with a /50 scale, enforces a quality gate (PASS 35+/FAIL), and writes a persisted report. Use /simplify for fast ad-hoc feedback; use /code-quality:review when you need a structured, scored, and documented assessment.

When to Use

Drupal projects:

  • "Setup quality tools" / "Install PHPStan"
  • "Run code audit" / "Check code quality"
  • "Check coverage" / "What's my coverage?"
  • "Find SOLID violations" / "Check complexity"
  • "Check duplication" / "DRY check"
  • "Lint code" / "Check coding standards"
  • "Fix deprecations" / "Run rector"
  • "Start TDD" / "RED-GREEN-REFACTOR"
  • "Check security" / "Find vulnerabilities" / "OWASP audit"

Next.js projects:

  • "Setup quality tools" / "Install ESLint"
  • "Run code audit" / "Check code quality"
  • "Check coverage" / "Run Jest coverage"
  • "Find SOLID violations" / "Check complexity" / "Check circular deps"
  • "Lint code" / "Run ESLint"
  • "Check duplication" / "DRY check"
  • "Start TDD" / "Jest watch mode"
  • "Check security" / "Find vulnerabilities" / "OWASP audit"

Quick Reference

Drupal Scripts

TaskScriptDetails
Setup toolsscripts/core/install-tools.shSee Drupal Setup
Full auditscripts/core/full-audit.shSee Full Audit
Coveragescripts/drupal/coverage-report.shSee Coverage Check
SOLID checkscripts/drupal/solid-check.shSee SOLID Check
DRY checkscripts/drupal/dry-check.shSee DRY Check
Lint checkscripts/drupal/lint-check.shSee Lint Check
Fix deprecationsscripts/drupal/rector-fix.shSee Rector Fix
TDD cyclescripts/drupal/tdd-workflow.shSee TDD Workflow
Security auditscripts/drupal/security-check.shSee Security Audit (10 layers)

Next.js Scripts

TaskScriptDetails
Setup toolsscripts/core/install-tools.shSee Next.js Setup
Full auditscripts/core/full-audit.shSee Full Audit
Coveragescripts/nextjs/coverage-report.shSee Coverage Check
SOLID checkscripts/nextjs/solid-check.shSee SOLID Check
Lint checkscripts/nextjs/lint-check.shSee Lint Check
DRY checkscripts/nextjs/dry-check.shSee DRY Check
TDD cyclescripts/nextjs/tdd-workflow.shSee TDD Workflow
Security auditscripts/nextjs/security-check.shSee Security Audit (7 layers)

Before Any Operation

Drupal:

  1. Locate Drupal root: check web/core/lib/Drupal.php or docroot/core/lib/Drupal.php
  2. Verify DDEV: ddev describe
  3. Create reports directory: mkdir -p.reports && echo ".reports/" >>.gitignore

Next.js:

  1. Verify npm: npm --version
  2. Create reports directory: mkdir -p.reports && echo ".reports/" >>.gitignore
Sandbox users: If Claude Code sandbox mode is enabled, bash scripts that invoke linters (PHPStan, ESLint, Semgrep, Trivy, Gitleaks) require their binary paths to be whitelisted. Add the tool binaries to your allowedPaths in claude_code_config.json (e.g., vendor/bin/phpstan, /usr/local/bin/semgrep). DDEV-proxied commands run inside the container and are unaffected.

When to Run What

Read decision-guides/quality-audit-checklist.md for detailed guidance.

ContextWhat to RunTime
Pre-commitquality:cs only~5s
Pre-pushPHPStan + Unit/Kernel tests~2min
Pre-mergeFull audit~10min
WeeklyFull audit + HTML reports~15min

Scope Targeting

To audit specific modules or components instead of the entire project:

See Scope Targeting for three approaches:

  1. Change directory (recommended) - cd web/modules/custom/my_module
  2. Environment variables - DRUPAL_MODULES_PATH=path/to/module
  3. Full scan (default) - Run from project root

Intelligent detection: Claude detects current directory and user intent.


Operations

All detailed operation instructions have been moved to reference files for better organization.

Drupal Operations

Setup & Configuration

Quality Audits

Development Workflows

Security

- Drush pm:security, Composer audit - yousha/php-security-linter, Psalm taint analysis - Custom Drupal patterns, Security Review module - Semgrep SAST, Trivy scanner, Gitleaks (v1.8.0) - Roave Security Advisories (v2.0.0)

Next.js Operations

Setup & Configuration

  • Operation 13: Setup Tools - Install ESLint, Jest, security tools

Quality Audits

Development Workflows

Security

- npm audit, ESLint security plugins - Semgrep SAST, Trivy scanner, Gitleaks (v1.8.0) - Custom React/Next.js patterns (XSS, eval, navigation) - Socket CLI (v2.0.0)

Optional: DAST (Dynamic Testing)

Pre-production security testing for staging environments

  • Operation 22: DAST Tools - Dynamic security testing (v2.1.0)

- OWASP ZAP (full DAST scanner) - Nuclei (template-based CVE scanning) - Requires running application - Use before releases on staging/pre-production


Saving Reports

All reports must follow schemas/audit-report.schema.json:

{
  "meta": {
    "project_type": "drupal|nextjs|monorepo",
    "timestamp": "2025-12-19T12:00:00Z",
    "thresholds": { "coverage_minimum": 70, "duplication_max": 5 }
  },
  "summary": {
    "overall_score": "pass|warning|fail",
    "coverage_score": "pass|warning|fail",
    "solid_score": "pass|warning|fail",
    "dry_score": "pass|warning|fail",
    "security_score": "pass|warning|fail"
  },
  "coverage": { "line_coverage": 75.5, "files_analyzed": 45 },
  "solid": { "violations": [] },
  "dry": { "duplication_percentage": 3.2, "clones": [] },
  "security": { "critical": 0, "high": 0, "medium": 3, "low": 5, "issues": [] },
  "recommendations": []
}

References

Core Guidance

  • references/tdd-workflow.md - RED-GREEN-REFACTOR patterns, test naming, cycle targets
  • references/coverage-metrics.md - Coverage targets by code type, PCOV vs Xdebug
  • references/dry-detection.md - Rule of Three, when duplication is OK
  • references/solid-detection.md - SOLID detection patterns and fixes
  • references/composer-scripts.md - Ready-to-use composer scripts
  • references/scope-targeting.md - Target specific modules/components (NEW in v1.8.0)

Operations

  • references/operations/drupal-setup.md - Drupal setup operations
  • references/operations/drupal-audits.md - Drupal quality audit operations
  • references/operations/drupal-security.md - Drupal security (10 layers, v2.0.0)
  • references/operations/drupal-tdd.md - Drupal TDD workflow
  • references/operations/nextjs-setup.md - Next.js setup operations
  • references/operations/nextjs-audits.md - Next.js quality audit operations
  • references/operations/nextjs-security.md - Next.js security (7 layers, v2.0.0)
  • references/operations/nextjs-tdd.md - Next.js TDD workflow

Online Dev-Guides (Drupal Domain)

For deeper Drupal-specific patterns beyond tool commands, fetch the guide index:

Index: https://camoa.github.io/dev-guides/llms.txt

Likely relevant topics: solid-principles, dry-principles, security, testing, tdd, js-development, github-actions

Usage: WebFetch the index to discover available topics, then fetch specific topic pages when explaining violations, suggesting fixes, or providing architectural context.

Decision Guides

  • decision-guides/test-type-selection.md - Unit vs Kernel vs Functional decision tree
  • decision-guides/quality-audit-checklist.md - When to run what (pre-commit vs pre-merge)

Templates

Drupal

  • templates/drupal/phpstan.neon - PHPStan 2.x config (extensions auto-load)
  • templates/drupal/phpmd.xml - PHPMD ruleset for Drupal
  • templates/drupal/phpunit.xml - PHPUnit config with testsuites
  • templates/ci/github-drupal.yml - GitHub Actions workflow with security tools

Next.js

  • templates/nextjs/eslint.config.js - ESLint v9 flat config with TypeScript + security
  • templates/nextjs/jest.config.js - Jest config with coverage thresholds
  • templates/nextjs/jest.setup.js - Jest setup with Testing Library
  • templates/nextjs/.prettierrc - Prettier config with Tailwind plugin

What's New in v2.1.0

Phase 3 - Optional DAST Tools (NEW!):

  • ✅ OWASP ZAP (full DAST scanner for pre-production)
  • ✅ Nuclei (template-based CVE and misconfiguration scanning)
  • ✅ Comprehensive documentation with usage examples
  • ✅ CI/CD integration guides (GitHub Actions, GitLab)
  • ✅ Pre-release checklist script

DAST Coverage:

  • Pre-production security testing
  • Runtime vulnerability detection
  • OWASP Top 10 dynamic testing
  • 1000+ CVE templates (Nuclei)

See references/operations/dast-tools.md for full documentation.


What's New in v2.0.0

Progressive Disclosure Refactoring:

  • ✅ SKILL.md: 632 → 234 lines (63% reduction)
  • ✅ 9 reference files created with full documentation
  • ✅ Plugin-creation-tools compliance (16/16 criteria)

Phase 1 - Cross-Stack Security Tools:

  • ✅ Semgrep SAST (20,000+ security rules for PHP, React, JS, TS)
  • ✅ Trivy scanner (dependency/container/secret scanner)
  • ✅ Gitleaks (secret detection with 800+ patterns)

Phase 2 - Enhancement Tools:

  • ✅ Roave Security Advisories (Drupal - Composer prevention layer)
  • ✅ Socket CLI (Next.js - supply chain attack detection)

Security Coverage:

  • Drupal: 40% → 90% (10 security layers)
  • Next.js: 0% → 85% (7 security layers)

See .work-in-progress-v2.0.0.md for full implementation details.

平台分布

Codex

37.81%
按下载量换算59

Claude

29.25%
按下载量换算45

Cursor

19.37%
按下载量换算30

Gemini CLI

9.54%
按下载量换算15

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills