Skip to content

Commit 34090fe

Browse files
committed
Lombok: Only do anything if Java is being analysed
1 parent 976ada2 commit 34090fe

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

src/init-action.ts

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -342,18 +342,20 @@ async function run() {
342342
core.exportVariable("CODEQL_EXTRACTOR_JAVA_AGENT_DISABLE_KOTLIN", "true");
343343
}
344344

345-
if (await features.getValue(Feature.CodeqlJavaLombokEnabled, codeql)) {
346-
logger.info("Enabling CodeQL Java Lombok support");
347-
core.exportVariable(
348-
"CODEQL_EXTRACTOR_JAVA_RUN_ANNOTATION_PROCESSORS",
349-
"true",
350-
);
351-
} else {
352-
logger.info("Disabling CodeQL Java Lombok support");
353-
core.exportVariable(
354-
"CODEQL_EXTRACTOR_JAVA_RUN_ANNOTATION_PROCESSORS",
355-
"false",
356-
);
345+
if (config.languages.includes(Language.java)) {
346+
if (await features.getValue(Feature.CodeqlJavaLombokEnabled, codeql)) {
347+
logger.info("Enabling CodeQL Java Lombok support");
348+
core.exportVariable(
349+
"CODEQL_EXTRACTOR_JAVA_RUN_ANNOTATION_PROCESSORS",
350+
"true",
351+
);
352+
} else {
353+
logger.info("Disabling CodeQL Java Lombok support");
354+
core.exportVariable(
355+
"CODEQL_EXTRACTOR_JAVA_RUN_ANNOTATION_PROCESSORS",
356+
"false",
357+
);
358+
}
357359
}
358360

359361
// Disable Python dependency extraction if feature flag set

0 commit comments

Comments
 (0)