Run PHP Copy-Paste Detector (PHPCPD)
run_phpcpdDetect duplicated code blocks in a directory using token-based analysis. Configure minimum token and line counts to ignore small duplicates.
Instructions
Tekrarlanan kod bloklarını tespit eder. Token tabanlı çalışır, küçük kod parçalarını yakalar.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"filepath": "<filepath>"
},
"name": "run_phpcpd"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filepath | Yes | Taranacak dizin. Örnek: ./src | |
| minLines | No | Minimum satır sayısı (varsayılan: 5). | |
| minTokens | No | Minimum token sayısı (varsayılan: 50). Daha küçük bloklar göz ardı edilir. | |
| projectPath | No | İsteğe bağlı proje kökü (otomatik tespit edilir). |