Paul Campbell
9057adddc3
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
closes kemitix/podal#5 Reviewed-on: #7 Co-authored-by: Paul Campbell <pcampbell@kemitix.net> Co-committed-by: Paul Campbell <pcampbell@kemitix.net>
34 lines
822 B
Rust
34 lines
822 B
Rust
use podal::prelude::*;
|
|
|
|
use podal::{feed::FeedEnv, fetch::FetchEnv, history::HistoryEnv};
|
|
|
|
fn main() -> Result<()> {
|
|
println!("Podal");
|
|
let subscriptions = "subscriptions.txt";
|
|
let history = "downloaded.txt";
|
|
let site = "https://www.youtube.com/";
|
|
|
|
podal::run(
|
|
subscriptions,
|
|
history,
|
|
site,
|
|
podal::Env {
|
|
feed: FeedEnv {
|
|
find: podal::feed::find,
|
|
get: podal::feed::reqwest_blocking_get,
|
|
},
|
|
|
|
history: HistoryEnv {
|
|
find: podal::history::find,
|
|
add: podal::history::add,
|
|
},
|
|
fetch: FetchEnv {
|
|
download: podal::fetch::download,
|
|
get: podal::fetch::get,
|
|
},
|
|
},
|
|
)?;
|
|
|
|
println!("Done");
|
|
Ok(())
|
|
}
|