Log build arguments received tooling API client

This commit is contained in:
Akash Yadav
2022-05-04 20:10:05 +05:30
parent f9dd28fdf9
commit 021d931636
2 changed files with 4 additions and 0 deletions
@@ -30,6 +30,7 @@ import org.gradle.tooling.ConfigurableLauncher;
import java.io.ByteArrayInputStream;
import java.nio.charset.StandardCharsets;
import java.util.Objects;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.Future;
@@ -70,7 +71,10 @@ public class Main {
if (client != null) {
try {
final var args = client.getBuildArguments().get();
args.removeIf(Objects::isNull);
args.removeIf(String::isBlank);
LOG.debug("Arguments from tooling client:", args);
launcher.addArguments(args);
} catch (Throwable e) {
LOG.error("Unable to get build arguments from tooling client", e);