poop-graph/src/main.rs

16 lines
415 B
Rust
Raw Normal View History

mod extract;
2022-04-05 18:21:33 -04:00
mod fetch;
2022-04-05 14:07:28 -04:00
use extract::DataSet;
2022-04-05 18:21:33 -04:00
use fetch::PdfFetcher;
2022-04-05 14:07:28 -04:00
2022-04-05 18:21:33 -04:00
#[tokio::main]
async fn main() {
let mut fetcher = PdfFetcher::new().expect("Failed to initialize PDF fetcher");
let doc = fetcher.fetch().await.expect("Failed to fetch PDF");
let dataset = DataSet::extract(&doc).expect("Failed to extract dataset");
for row in dataset.csv_rows() {
println!("{}", row.unwrap());
2022-04-05 14:07:28 -04:00
}
}