From 8dcd2807ee81dc65e872e0d62273cdc7cee58ed2 Mon Sep 17 00:00:00 2001 From: mo khan Date: Thu, 10 Jul 2025 14:14:54 -0600 Subject: chore: validate the generated entities.json --- src/bin/cli.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/bin') diff --git a/src/bin/cli.rs b/src/bin/cli.rs index 0751ed05..fc70ae82 100644 --- a/src/bin/cli.rs +++ b/src/bin/cli.rs @@ -53,8 +53,15 @@ async fn main() -> Result<(), Box> { } => { let repository = EntitiesRepository::new(Api::new(token, host)); let entities = repository.all(project).await?; + EntitiesRepository::is_valid(&entities)?; let json = serde_json::to_string_pretty(&entities)?; - std::fs::write(output, json)?; + std::fs::write(&output, json)?; + + println!( + "Successfully generated {} entities to {}", + entities.len(), + output + ); } } -- cgit v1.2.3