Developers can trigger a security scan manually by following these steps:
- Installing the CLI Tool: Run
npm install -g @anthropic-ai/claude-code
Install the Claude Code CLI. - Navigate to the project directory: Make sure the directory is a Git repository (if not, run the
git init
). - Starting the CLI: In the terminal, type
claude
Start the Claude Code terminal. - Run command: Input
/security-review
This tool analyzes the current Git staging area for code changes and generates a report.
Note: If the directory is not a Git repository, the command will result in an error message fatal: not a git repository
You need to initialize your Git repository at this point.
This answer comes from the articleClaude Code Security Review: a GitHub tool to automate code security vulnerability scanningThe