From 5c5a52d9600eb9ea911f63d3d322acba4d04487e Mon Sep 17 00:00:00 2001 From: Samuel Orji Date: Fri, 6 Oct 2023 14:53:14 +0100 Subject: [PATCH] set default download branch to main instead of master (#191) Signed-off-by: samuel orji --- api_generator/src/bin/run.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api_generator/src/bin/run.rs b/api_generator/src/bin/run.rs index 510c055a..7097dbf8 100644 --- a/api_generator/src/bin/run.rs +++ b/api_generator/src/bin/run.rs @@ -35,13 +35,14 @@ fn main() -> anyhow::Result<()> { let download_dir = fs::canonicalize(Path::new("./api_generator/rest_specs"))?; let generated_dir = fs::canonicalize(Path::new("./opensearch/src"))?; let last_downloaded_version = Path::new("./api_generator/rest_specs/last_downloaded_version"); + let default_specification_download_branch = String::from("main"); let mut download_specs = false; let mut answer = String::new(); let default_branch = if last_downloaded_version.exists() { fs::read_to_string(last_downloaded_version)? } else { - String::from("master") + default_specification_download_branch }; let mut branch = default_branch.clone();