mirror of
https://github.com/github/codeql.git
synced 2025-12-30 23:58:15 +01:00
19 lines
534 B
Plaintext
19 lines
534 B
Plaintext
/**
|
|
* @name Lines of commented-out code in files
|
|
* @description The number of lines of commented-out code in a file.
|
|
* @kind treemap
|
|
* @treemap.warnOn highValues
|
|
* @metricType file
|
|
* @metricAggregate avg sum max
|
|
* @precision high
|
|
* @id java/lines-of-commented-out-code-in-files
|
|
* @tags maintainability
|
|
* documentation
|
|
*/
|
|
|
|
import Violations_of_Best_Practice.Comments.CommentedCode
|
|
|
|
from File f, int n
|
|
where n = sum(CommentedOutCode comment | comment.getFile() = f | comment.getCodeLines())
|
|
select f, n order by n desc
|