mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-07-27 08:41:00 +00:00
move the flatten-serde-json crate inside of milli
This commit is contained in:
11
flatten-serde-json/src/main.rs
Normal file
11
flatten-serde-json/src/main.rs
Normal file
@ -0,0 +1,11 @@
|
||||
use std::io::stdin;
|
||||
|
||||
use flatten_serde_json::flatten;
|
||||
use serde_json::{Map, Value};
|
||||
|
||||
fn main() {
|
||||
let json: Map<String, Value> = serde_json::from_reader(stdin()).unwrap();
|
||||
|
||||
let result = flatten(&json);
|
||||
println!("{}", serde_json::to_string_pretty(&result).unwrap());
|
||||
}
|
Reference in New Issue
Block a user