Skip to content

Commit 49f74ba

Browse files
authored
Merge pull request #16729 from mbaluda/main
JS: Extract SAP XSJS file types as Javascript
2 parents 988d067 + b75514c commit 49f74ba

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

javascript/extractor/src/com/semmle/js/extractor/AutoBuild.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
*
152152
* <ul>
153153
* <li>All JavaScript files, that is, files with one of the extensions supported by {@link
154-
* FileType#JS} (currently ".js", ".jsx", ".mjs", ".cjs", ".es6", ".es").
154+
* FileType#JS} (currently ".js", ".jsx", ".mjs", ".cjs", ".es6", ".es", ".xsjs", ".xsjslib").
155155
* <li>All HTML files, that is, files with with one of the extensions supported by {@link
156156
* FileType#HTML} (currently ".htm", ".html", ".xhtm", ".xhtml", ".vue", ".html.erb", ".html.dot", ".jsp").
157157
* <li>All YAML files, that is, files with one of the extensions supported by {@link

javascript/extractor/src/com/semmle/js/extractor/FileExtractor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ protected boolean contains(File f, String lcExt, ExtractorConfig config) {
135135
}
136136
},
137137

138-
JS(".js", ".jsx", ".mjs", ".cjs", ".es6", ".es") {
138+
JS(".js", ".jsx", ".mjs", ".cjs", ".es6", ".es", ".xsjs", ".xsjslib") {
139139
@Override
140140
public IExtractor mkExtractor(ExtractorConfig config, ExtractorState state) {
141141
return new ScriptExtractor(config, state);

javascript/extractor/test/com/semmle/js/extractor/test/AutoBuildTests.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,8 @@ public void basicTest() throws IOException {
178178
addFile(true, LGTM_SRC, "tst.js");
179179
addFile(true, LGTM_SRC, "tst.ts");
180180
addFile(true, LGTM_SRC, "tst.html");
181+
addFile(true, LGTM_SRC, "tst.xsjs");
182+
addFile(true, LGTM_SRC, "tst.xsjslib");
181183
addFile(false, LGTM_SRC, "tst.json");
182184
addFile(true, LGTM_SRC, "package.json");
183185
addFile(true, LGTM_SRC, ".eslintrc.yml");

0 commit comments

Comments
 (0)