AgentSkillsCN

code-reviewer

审查Java代码的最佳实践、安全问题和Spring Framework规范。当用户要求审查、分析或审计代码时使用。

SKILL.md
--- frontmatter
name: code-reviewer
description: Reviews Java code for best practices, security issues, and Spring Framework conventions. Use when user asks to review, analyze, or audit code.

Code Reviewer

Instructions

在审查代码时:

  1. 检查是否存在安全漏洞(如SQL注入、XSS等)
  2. 验证是否遵循了Spring Boot的最佳实践(如正确使用@Service、@Repository等注解)
  3. 查找潜在的空指针异常
  4. 提出提高代码可读性和可维护性的建议
  5. 提供具体的逐行反馈,并附上代码示例
  6. 以中文的方式返回代码评审结果