Skip to content

Commit 651bc51

Browse files
authored
Only download automodel query pack when relevant (#2830)
1 parent 297260a commit 651bc51

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

extensions/ql-vscode/src/model-editor/model-editor-queries.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { writeFile } from "fs-extra";
44
import { dump } from "js-yaml";
55
import { prepareExternalApiQuery } from "./external-api-usage-queries";
66
import { CodeQLCliServer } from "../codeql-cli/cli";
7+
import { showLlmGeneration } from "../config";
78

89
/**
910
* setUpPack sets up a directory to use for the data extension editor queries.
@@ -40,7 +41,10 @@ export async function setUpPack(
4041

4142
// Install the other needed query packs
4243
await cliServer.packDownload([`codeql/${language}-queries`]);
43-
await cliServer.packDownload([`codeql/${language}-automodel-queries`]);
44+
45+
if (language === "java" && showLlmGeneration()) {
46+
await cliServer.packDownload([`codeql/${language}-automodel-queries`]);
47+
}
4448

4549
return true;
4650
}

0 commit comments

Comments
 (0)