From c8d17372cbb70798f66d3d7f7ab33e65cc5a4abb Mon Sep 17 00:00:00 2001 From: Joshua Li Date: Tue, 30 May 2023 22:55:56 +0000 Subject: [PATCH] Update test setup Signed-off-by: Joshua Li --- .gitignore | 4 +++- doctest/build.gradle | 7 +++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 2b1f9be522..1b892036dd 100644 --- a/.gitignore +++ b/.gitignore @@ -47,4 +47,6 @@ gen .java-version .worktrees -http-client.env.json \ No newline at end of file +http-client.env.json +/doctest/sql-cli/ +.factorypath diff --git a/doctest/build.gradle b/doctest/build.gradle index 4fa0e6e00f..273d51fce2 100644 --- a/doctest/build.gradle +++ b/doctest/build.gradle @@ -19,9 +19,12 @@ def path = project(':').projectDir // plugin module, and will only build ppl in it. def plugin_path = project(':doctest').projectDir -task cloneSqlCli(type: Exec) { +task cloneSqlCli() { // clone the sql-cli repo locally - commandLine 'git', 'clone', 'https://github.com/opensearch-project/sql-cli.git' + def cliRepo = new File("$projectDir/sql-cli") + if(!cliRepo.exists()) { + exec { commandLine 'git', 'clone', 'https://github.com/opensearch-project/sql-cli.git' } + } } task bootstrap(type: Exec, dependsOn: ['cloneSqlCli']) {