diff --git a/.gitignore b/.gitignore index 706a885..44d2f28 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +dump.txt tmp/ .corpora/.id test-corpora/ diff --git a/md/notes/corpora-name.md b/md/notes/corpora-name.md new file mode 100644 index 0000000..f021045 --- /dev/null +++ b/md/notes/corpora-name.md @@ -0,0 +1,43 @@ +The name "corpora" and its variations like "encorpora" carry strong, positive connotations in English and Romance languages, as you suggest. Here's a breakdown of how the sound and meaning might resonate in different languages: + +### **English** +- **Corpora**: Directly evokes the idea of "collections" or "bodies" of text/data, as it's the plural of "corpus." This ties neatly into your project, which deals with textual or multimodal collections. +- **Encorpora**: Suggests an action or process, like "incorporating" something into a body or system, with a dynamic and forward-looking tone. + +### **Romance Languages** +1. **Spanish** + - **Corpora**: Can resonate with "cuerpo" (body) or "corporación" (corporation), suggesting something organized, structured, or collective. It also connects with academic corpora (linguistic or textual collections). + - **Encorpora**: Sounds similar to "incorporar" (to incorporate, include, or embody). This implies action, integration, and growth, aligning with innovative tools. + +2. **Portuguese** + - **Corpora**: Similar to Spanish, evokes "corpo" (body) and structured collections. It's also understood academically in the context of textual data or linguistics. + - **Encorpora**: Aligns with "incorporar" and conveys the same sense of integrating or embodying something. + +3. **Italian** + - **Corpora**: Evokes "corpo" (body) and structured entities. Linguists and academics would recognize it as a collection of texts or data. + - **Encorpora**: Closely tied to "incorporare" (to incorporate, include, or merge). The prefix "en-" suggests action, forward movement, or transformation. + +4. **French** + - **Corpora**: Resonates with "corps" (body) and collections. While not as commonly used outside academic circles, it's recognizable. + - **Encorpora**: Relates to "incorporer" (to incorporate or include) and has an innovative and integrative vibe. + +### **Other Language Families** +1. **Germanic Languages** + - In **German**, "corpora" might evoke academic or technical contexts (linguistic corpora). It might sound slightly formal but understandable in educated circles. + - In **Dutch**, similar to German, "corpora" would align with its academic or structural use. + +2. **Slavic Languages** + - **Corpora** may not immediately resonate in Slavic languages but is increasingly recognized due to its use in international academic and tech contexts. It could sound modern or technical. + - **Encorpora**: Might not have direct meaning but carries an intuitive, positive sound. + +3. **Asian Languages** + - In languages like **Japanese** or **Korean**, "corpora" would likely be transliterated phonetically, taking on a modern and tech-savvy connotation. Its connection to "corpus" (data/text collection) in tech contexts would be understood. + - **Encorpora**: The "en-" prefix might signal something dynamic or global in a tech-related context. + +### **Overall Connotations** +- **Corpora**: Structured, academic, intelligent, and related to "bodies" of work or collections of data. +- **Encorpora**: Suggests action, integration, inclusion, and innovation, with a more dynamic and progressive feel. + +Both names work wonderfully for a modern tool or platform. Their linguistic accessibility and appealing connotations across multiple languages make them excellent choices for a global audience. + +**Corpora** gives a solid, authoritative vibe for your foundation, while **Encorpora** suggests growth, evolution, and activity — perfect for a self-evolving AI-powered tool! \ No newline at end of file diff --git a/rs/Cargo.lock b/rs/Cargo.lock index 7ab7fd4..92561b3 100644 --- a/rs/Cargo.lock +++ b/rs/Cargo.lock @@ -138,6 +138,8 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd9de9f2205d5ef3fd67e685b0df337994ddd4495e2a28d185500d0e1edfea47" dependencies = [ + "jobserver", + "libc", "shlex", ] @@ -227,6 +229,16 @@ name = "corpora" version = "0.1.0" dependencies = [ "clap", + "corpora_client", + "flate2", + "git2", + "reqwest", + "serde", + "serde_json", + "serde_yaml", + "tar", + "tempfile", + "uuid", ] [[package]] @@ -242,6 +254,15 @@ dependencies = [ "uuid", ] +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + [[package]] name = "darling" version = "0.20.10" @@ -329,6 +350,28 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "486f806e73c5707928240ddc295403b1b93c96a02038563881c4a2fd84b81ac4" +[[package]] +name = "filetime" +version = "0.2.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c0522e981e68cbfa8c3f978441a5f34b30b96e146b33cd3359176b50fe8586" +dependencies = [ + "cfg-if", + "libc", + "libredox", + "windows-sys 0.59.0", +] + +[[package]] +name = "flate2" +version = "1.0.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + [[package]] name = "fnv" version = "1.0.7" @@ -426,6 +469,21 @@ version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f" +[[package]] +name = "git2" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b903b73e45dc0c6c596f2d37eccece7c1c8bb6e4407b001096387c63d0d93724" +dependencies = [ + "bitflags", + "libc", + "libgit2-sys", + "log", + "openssl-probe", + "openssl-sys", + "url", +] + [[package]] name = "h2" version = "0.4.6" @@ -795,6 +853,15 @@ version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" +[[package]] +name = "jobserver" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48d1dbcbbeb6a7fec7e059840aa538bd62aaccf972c7346c4d9d2059312853d0" +dependencies = [ + "libc", +] + [[package]] name = "js-sys" version = "0.3.72" @@ -810,6 +877,57 @@ version = "0.2.162" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "18d287de67fe55fd7e1581fe933d965a5a9477b38e949cfa9f8574ef01506398" +[[package]] +name = "libgit2-sys" +version = "0.17.0+1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10472326a8a6477c3c20a64547b0059e4b0d086869eee31e6d7da728a8eb7224" +dependencies = [ + "cc", + "libc", + "libssh2-sys", + "libz-sys", + "openssl-sys", + "pkg-config", +] + +[[package]] +name = "libredox" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" +dependencies = [ + "bitflags", + "libc", + "redox_syscall", +] + +[[package]] +name = "libssh2-sys" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2dc8a030b787e2119a731f1951d6a773e2280c660f8ec4b0f5e1505a386e71ee" +dependencies = [ + "cc", + "libc", + "libz-sys", + "openssl-sys", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "libz-sys" +version = "1.1.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2d16453e800a8cf6dd2fc3eb4bc99b786a9b90c663b8559a5b1a041bf89e472" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + [[package]] name = "linux-raw-sys" version = "0.4.14" @@ -1010,6 +1128,15 @@ dependencies = [ "proc-macro2", ] +[[package]] +name = "redox_syscall" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b6dfecf2c74bce2466cabf93f6664d6998a69eb21e39f4207930065b27b771f" +dependencies = [ + "bitflags", +] + [[package]] name = "reqwest" version = "0.12.9" @@ -1188,9 +1315,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.132" +version = "1.0.133" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d726bfaff4b320266d395898905d0eba0345aae23b54aee3a737e260fd46db03" +checksum = "c7fceb2473b9166b2294ef05efcb65a3db80803f0b03ef86a5fc88a2b85ee377" dependencies = [ "itoa", "memchr", @@ -1251,6 +1378,19 @@ dependencies = [ "syn", ] +[[package]] +name = "serde_yaml" +version = "0.9.34+deprecated" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47" +dependencies = [ + "indexmap 2.6.0", + "itoa", + "ryu", + "serde", + "unsafe-libyaml", +] + [[package]] name = "shlex" version = "1.3.0" @@ -1358,6 +1498,17 @@ dependencies = [ "libc", ] +[[package]] +name = "tar" +version = "0.4.43" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c65998313f8e17d0d553d28f91a0df93e4dbbbf770279c7bc21ca0f09ea1a1f6" +dependencies = [ + "filetime", + "libc", + "xattr", +] + [[package]] name = "tempfile" version = "3.14.0" @@ -1504,6 +1655,12 @@ version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe" +[[package]] +name = "unsafe-libyaml" +version = "0.2.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "673aac59facbab8a9007c7f6108d11f63b603f7cabff99fabf650fea5c32b861" + [[package]] name = "untrusted" version = "0.9.0" @@ -1780,6 +1937,17 @@ version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51" +[[package]] +name = "xattr" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8da84f1a25939b27f6820d92aed108f83ff920fdf11a7b19366c27c4cda81d4f" +dependencies = [ + "libc", + "linux-raw-sys", + "rustix", +] + [[package]] name = "yoke" version = "0.7.4" diff --git a/rs/core/corpora_cli/Cargo.toml b/rs/core/corpora_cli/Cargo.toml index fb61159..a5f44e1 100644 --- a/rs/core/corpora_cli/Cargo.toml +++ b/rs/core/corpora_cli/Cargo.toml @@ -5,3 +5,13 @@ edition = "2021" [dependencies] clap = { version = "4.5.21", features = ["derive"] } +corpora_client = { path = "../corpora_client" } +flate2 = "1.0.35" +git2 = "0.19.0" +reqwest = "0.12.9" +serde = "1.0.215" +serde_json = "1.0.133" +serde_yaml = "0.9.34" +tar = "0.4.43" +tempfile = "3.14.0" +uuid = "1.11.0" diff --git a/rs/core/corpora_cli/src/commands/init.rs b/rs/core/corpora_cli/src/commands/init.rs index 9c16741..3e3bf2c 100644 --- a/rs/core/corpora_cli/src/commands/init.rs +++ b/rs/core/corpora_cli/src/commands/init.rs @@ -1,4 +1,117 @@ -/// Run the `init` command -pub fn run() { - println!("init command executed with no arguments."); +use crate::context::Context; +use flate2::write::GzEncoder; +use flate2::Compression; +use std::io::Write; +use std::{fs, io, path::Path, process::Command}; + +pub fn run(ctx: &Context) { + println!("Initializing a new corpus..."); + + let corpus_name = ctx.corpora_config.name.clone(); + let url = Some(ctx.corpora_config.url.clone()); + + // Determine the root path of the repository (where .corpora.yaml is located) + let root_path = match find_repo_root() { + Some(path) => path, + None => { + eprintln!("Failed to determine the root of the repository."); + return; + } + }; + + // Generate a tarball of all tracked files and save to a temporary file + let tarball_path = match create_tarball_from_git(&root_path) { + Ok(path) => path, + Err(err) => { + eprintln!("Failed to create tarball: {:?}", err); + return; + } + }; + + // Call the API to create a new corpus + match corpora_client::apis::corpus_api::create_corpus( + &ctx.api_config, + &corpus_name, + tarball_path.clone(), + url.as_deref(), + ) { + Ok(response) => { + println!("Corpus created successfully: {:?}", response); + + // Write the response ID to `.corpora/.id` + if let Err(err) = write_corpus_id(&root_path, &response.id) { + eprintln!("Failed to write corpus ID: {:?}", err); + } + } + Err(err) => { + eprintln!("Failed to create corpus: {:?}", err); + } + } + + // Clean up the temporary tarball file + if let Err(err) = fs::remove_file(tarball_path) { + eprintln!("Failed to remove temporary tarball: {:?}", err); + } +} + +/// Find the root directory of the Git repository +fn find_repo_root() -> Option { + let repo = git2::Repository::discover(".").ok()?; + repo.workdir().map(|path| path.to_path_buf()) +} + +/// Create a tarball of all tracked files in the Git repository and save to a temporary file +fn create_tarball_from_git(root_path: &Path) -> io::Result { + let output = Command::new("git") + .arg("ls-files") + .current_dir(root_path) + .output()?; + + if !output.status.success() { + return Err(io::Error::new( + io::ErrorKind::Other, + "Failed to list tracked files with git.", + )); + } + + let files = String::from_utf8_lossy(&output.stdout) + .lines() + .map(|line| root_path.join(line)) + .collect::>(); + + let tarball_path = root_path.join("temp_tarball.tar.gz"); + let tar_gz_file = fs::File::create(&tarball_path)?; + let mut encoder = GzEncoder::new(tar_gz_file, Compression::default()); + + { + let mut tar = tar::Builder::new(&mut encoder); + for file_path in files { + if file_path.is_file() { + let file_name = file_path.strip_prefix(root_path).unwrap(); + let mut file = fs::File::open(&file_path)?; + tar.append_file(file_name, &mut file)?; + } + } + tar.finish()?; + } + + encoder.finish()?; + Ok(tarball_path) +} + +/// Write the corpus ID to `.corpora/.id` in the root path +fn write_corpus_id(root_path: &Path, id: &uuid::Uuid) -> io::Result<()> { + let corpora_dir = root_path.join(".corpora"); + let id_file_path = corpora_dir.join(".id"); + + // Ensure `.corpora` directory exists + if !corpora_dir.exists() { + fs::create_dir_all(&corpora_dir)?; + } + + // Write the ID to `.corpora/.id` + let mut id_file = fs::File::create(id_file_path)?; + writeln!(id_file, "{}", id)?; + + Ok(()) } diff --git a/rs/core/corpora_cli/src/commands/issue/create.rs b/rs/core/corpora_cli/src/commands/issue/create.rs index 5204c27..360be91 100644 --- a/rs/core/corpora_cli/src/commands/issue/create.rs +++ b/rs/core/corpora_cli/src/commands/issue/create.rs @@ -1,4 +1,6 @@ +use crate::context::Context; /// Run the `create` subcommand -pub fn run() { +pub fn run(ctx: &Context) { println!("Creating issue"); + println!("Server URL: {}", ctx.api_config.base_path); } diff --git a/rs/core/corpora_cli/src/commands/issue/label.rs b/rs/core/corpora_cli/src/commands/issue/label.rs index bcfba2a..ef6400d 100644 --- a/rs/core/corpora_cli/src/commands/issue/label.rs +++ b/rs/core/corpora_cli/src/commands/issue/label.rs @@ -1,3 +1,4 @@ +use crate::context::Context; use clap::Args; /// Arguments for the `label` subcommand @@ -8,6 +9,7 @@ pub struct LabelArgs { } /// Run the `label` subcommand -pub fn run(args: LabelArgs) { +pub fn run(ctx: &Context, args: LabelArgs) { println!("Labeling issue with ID: {}", args.id); + println!("Server URL: {}", ctx.api_config.base_path); } diff --git a/rs/core/corpora_cli/src/commands/issue/update.rs b/rs/core/corpora_cli/src/commands/issue/update.rs index ebd9586..e063cd3 100644 --- a/rs/core/corpora_cli/src/commands/issue/update.rs +++ b/rs/core/corpora_cli/src/commands/issue/update.rs @@ -1,3 +1,4 @@ +use crate::context::Context; use clap::Args; /// Arguments for the `update` subcommand @@ -8,6 +9,7 @@ pub struct UpdateArgs { } /// Run the `update` subcommand -pub fn run(args: UpdateArgs) { +pub fn run(ctx: &Context, args: UpdateArgs) { println!("Updating issue with ID: {}", args.id); + println!("Server URL: {}", ctx.api_config.base_path); } diff --git a/rs/core/corpora_cli/src/commands/sync.rs b/rs/core/corpora_cli/src/commands/sync.rs index 7963da6..a0cfd7d 100644 --- a/rs/core/corpora_cli/src/commands/sync.rs +++ b/rs/core/corpora_cli/src/commands/sync.rs @@ -1,4 +1,7 @@ +use crate::context::Context; + /// Run the `sync` command -pub fn run() { +pub fn run(ctx: &Context) { println!("sync command executed with no arguments."); + println!("Server URL: {}", ctx.api_config.base_path); } diff --git a/rs/core/corpora_cli/src/commands/workon.rs b/rs/core/corpora_cli/src/commands/workon.rs index 92cf025..1230a4a 100644 --- a/rs/core/corpora_cli/src/commands/workon.rs +++ b/rs/core/corpora_cli/src/commands/workon.rs @@ -1,3 +1,4 @@ +use crate::context::Context; use clap::Args; /// The `workon` command arguments @@ -8,6 +9,7 @@ pub struct WorkonArgs { } /// Run the `workon` command -pub fn run(args: WorkonArgs) { +pub fn run(ctx: &Context, args: WorkonArgs) { println!("Workon command executed with path: {}", args.path); + println!("Server URL: {}", ctx.api_config.base_path); } diff --git a/rs/core/corpora_cli/src/context.rs b/rs/core/corpora_cli/src/context.rs new file mode 100644 index 0000000..3c6c5ff --- /dev/null +++ b/rs/core/corpora_cli/src/context.rs @@ -0,0 +1,143 @@ +use corpora_client::apis::configuration::Configuration; +use serde::{Deserialize, Serialize}; +use std::{env, fs}; + +#[derive(Serialize, Deserialize, Debug)] +pub struct ServerConfig { + pub base_url: String, +} + +#[derive(Serialize, Deserialize, Debug)] +/// Configuration from a .corpora.yaml file +pub struct CorporaConfig { + pub name: String, + pub server: ServerConfig, + pub url: String, +} + +pub struct Context { + pub api_config: Configuration, + pub corpora_config: CorporaConfig, +} + +impl Context { + /// Initialize a new context with OAuth authentication and configuration + pub fn new() -> Self { + // Derive name and URL from `.corpora.yaml` or Git + let (name, url) = match Self::find_corpora_config() { + Some(config) => (config.name, config.url), + None => { + eprintln!("Could not find `.corpora.yaml`. Falling back to Git-derived values..."); + Self::from_git_repo().unwrap_or_else(|| { + panic!("This is not a Git repository and `.corpora.yaml` is missing.") + }) + } + }; + + // Get server.base_url from .corpora.yaml or use default + let server_base_url = + Self::get_server_base_url().unwrap_or_else(|| "http://app:8877".to_string()); + + let corpora_config = CorporaConfig { + name, + server: ServerConfig { + base_url: server_base_url.clone(), + }, + url, + }; + + // Fetch client ID and secret from environment variables + let client_id = env::var("CORPORA_CLIENT_ID") + .expect("Environment variable CORPORA_CLIENT_ID is not set"); + let client_secret = env::var("CORPORA_CLIENT_SECRET") + .expect("Environment variable CORPORA_CLIENT_SECRET is not set"); + + // Perform OAuth authentication to fetch a bearer token + let bearer_access_token = + Self::get_oauth_token(&client_id, &client_secret, &server_base_url); + + // Configure the client using a struct literal + let api_config = Configuration { + base_path: server_base_url, + bearer_access_token: Some(bearer_access_token), + ..Default::default() + }; + + Context { + api_config, + corpora_config, + } + } + + /// Search for `.corpora.yaml` in the current directory or its parents + fn find_corpora_config() -> Option { + let mut current_dir = std::env::current_dir().ok()?; + loop { + let config_path = current_dir.join(".corpora.yaml"); + if config_path.exists() { + let contents = fs::read_to_string(&config_path).ok()?; + return serde_yaml::from_str(&contents).ok(); + } + + // Move to the parent directory + if !current_dir.pop() { + break; // We've reached the filesystem root + } + } + None + } + + /// Derive `name` and `url` from a Git repository + fn from_git_repo() -> Option<(String, String)> { + let repo = git2::Repository::discover(".").ok()?; + let remote = repo.find_remote("origin").ok()?; + let remote_url = remote.url()?.to_string(); + + // Derive the name and URL + let name = remote_url + .split('/') + .last() + .unwrap_or_default() + .trim_end_matches(".git") + .to_string(); + + Some((name, remote_url)) + } + + /// Get `server.base_url` from `.corpora.yaml` or return `None` + fn get_server_base_url() -> Option { + Self::find_corpora_config().map(|config| config.server.base_url) + } + + /// Perform OAuth authentication and fetch a bearer token + fn get_oauth_token(client_id: &str, client_secret: &str, server_url: &str) -> String { + let token_url = format!("{}/o/token/", server_url); + + let client = reqwest::blocking::Client::new(); + let response = client + .post(&token_url) + .form(&[ + ("grant_type", "client_credentials"), + ("client_id", client_id), + ("client_secret", client_secret), + ]) + .send() + .expect("Failed to perform OAuth authentication"); + + if !response.status().is_success() { + panic!( + "Failed to fetch OAuth token: {}", + response.text().unwrap_or_default() + ); + } + + let token_response: serde_json::Value = response + .json() + .expect("Failed to parse OAuth token response as JSON"); + + token_response["access_token"] + .as_str() + .expect("Access token not found in OAuth response") + .to_string() + } +} diff --git a/rs/core/corpora_cli/src/main.rs b/rs/core/corpora_cli/src/main.rs index 1bc16a2..613ecde 100644 --- a/rs/core/corpora_cli/src/main.rs +++ b/rs/core/corpora_cli/src/main.rs @@ -1,7 +1,9 @@ mod commands; +mod context; use clap::Parser; use commands::{issue, Commands}; +use context::Context; /// The main CLI app definition #[derive(Parser)] @@ -18,15 +20,16 @@ struct Cli { fn main() { let cli = Cli::parse(); + let ctx = Context::new(); match cli.command { - Commands::Init => commands::init::run(), - Commands::Sync => commands::sync::run(), - Commands::Workon(args) => commands::workon::run(args), + Commands::Init => commands::init::run(&ctx), + Commands::Sync => commands::sync::run(&ctx), + Commands::Workon(args) => commands::workon::run(&ctx, args), Commands::Issue(issue_command) => match issue_command { - issue::IssueCommands::Create => issue::create(), - issue::IssueCommands::Update(args) => issue::update(args), - issue::IssueCommands::Label(args) => issue::label(args), + issue::IssueCommands::Create => issue::create(&ctx), + issue::IssueCommands::Update(args) => issue::update(&ctx, args), + issue::IssueCommands::Label(args) => issue::label(&ctx, args), }, } } diff --git a/rs/genall.sh b/rs/genall.sh index 2459568..7a03b73 100755 --- a/rs/genall.sh +++ b/rs/genall.sh @@ -17,7 +17,6 @@ npx @openapitools/openapi-generator-cli generate \ -i "$TEMP_DIR/openapi.json" \ -g rust \ -o "$TEMP_DIR/corpora_client" \ - --template-dir "templates" \ --additional-properties=packageName=corpora_client,library=reqwest,supportAsync=false echo "Step 3: Moving generated code to $OUTPUT_DIR..."