sonar-duplication
Installation
SKILL.md
SonarQube — Duplication
List files that contain duplicated code in a SonarQube project, then drill into duplication blocks for a specific file when needed.
Usage
sonar-duplication # all duplicated files in the current project (auto-paginated)
sonar-duplication my-project # duplicated files in a specific project
sonar-duplication my-project --pr 42 # same, on a pull request
sonar-duplication my-project --page-size 100 --page 2 # single page of results (manual pagination)
sonar-duplication my-project --file src/auth/login.py # duplication detail for one file
Prerequisites
This skill requires the SonarQube MCP Server to be configured and the tools mcp__sonarqube__search_duplicated_files and mcp__sonarqube__get_duplications to be available in your session.
Before proceeding, verify the tools are accessible. If they are not, try the sonar api CLI fallback in Step 3 before giving up — don't invent other CLI commands (e.g. sonar mcp call or sonar duplication do not exist).