зеркало из https://github.com/github/codeql.git
Merge pull request #2246 from esbena/js/classify-doxygen
Approved by max-schaefer
This commit is contained in:
Коммит
d71fe0bffd
|
@ -14,6 +14,7 @@
|
|||
|
||||
* TypeScript 3.6 features are supported.
|
||||
|
||||
* Automatic classification of generated files has been improved, in particular files generated by Doxygen are now recognized.
|
||||
|
||||
## New queries
|
||||
|
||||
|
|
|
@ -137,6 +137,11 @@ private predicate isGeneratedHtml(File f) {
|
|||
e.getAttributeByName("name").getValue() = "generator"
|
||||
)
|
||||
or
|
||||
exists(HTML::CommentNode comment |
|
||||
comment.getText().regexpMatch("\\s*Generated by [\\w-]+ \\d+\\.\\d+\\.\\d+\\s*") and
|
||||
comment.getFile() = f
|
||||
)
|
||||
or
|
||||
20 < countStartingHtmlElements(f, _)
|
||||
}
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
| ai.1.2.3-build0123.js:0:0:0:0 | ai.1.2.3-build0123.js | library |
|
||||
| bundle-directive.js:0:0:0:0 | bundle-directive.js | generated |
|
||||
| data.js:0:0:0:0 | data.js | generated |
|
||||
| doxygen-generated.html:0:0:0:0 | doxygen-generated.html | generated |
|
||||
| etherpad.html:0:0:0:0 | etherpad.html | generated |
|
||||
| exported-data.js:0:0:0:0 | exported-data.js | generated |
|
||||
| htmltidy.html:0:0:0:0 | htmltidy.html | generated |
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html><head>
|
||||
<title></title>
|
||||
</head><body>
|
||||
<!-- Generated by Doxygen 1.8.6 -->
|
||||
<span onclick="javascript:;">1</span>
|
||||
</body>
|
||||
</html>
|
Загрузка…
Ссылка в новой задаче