Allow specifying an intent with the qp-rake1 CLI

This commit is contained in:
Olivier 'reivilibre' 2022-03-27 19:03:21 +01:00
parent a31566a89f
commit 7bdd7d4fc6

View File

@ -76,7 +76,9 @@ pub async fn main() -> anyhow::Result<()> {
page_extraction: PageExtractionService::new(adblock_engines)?, page_extraction: PageExtractionService::new(adblock_engines)?,
}; };
let outcome = raker.rake(&opts.url, RakeIntent::Any, &client).await?; let outcome = raker
.rake(&opts.url, opts.intent.unwrap_or(RakeIntent::Any), &client)
.await?;
match outcome { match outcome {
RakeOutcome::RakedPage(page) => { RakeOutcome::RakedPage(page) => {