mirror of
https://github.com/crunchy-labs/crunchy-cli.git
synced 2026-01-21 12:12:00 -06:00
Update dependencies and version
This commit is contained in:
parent
172e3612d0
commit
283a3802b2
11 changed files with 273 additions and 203 deletions
|
|
@ -134,7 +134,6 @@ pub struct Archive {
|
|||
pub(crate) urls: Vec<String>,
|
||||
}
|
||||
|
||||
#[async_trait::async_trait(?Send)]
|
||||
impl Execute for Archive {
|
||||
fn pre_check(&mut self) -> Result<()> {
|
||||
if !has_ffmpeg() {
|
||||
|
|
|
|||
|
|
@ -45,7 +45,6 @@ impl ArchiveFilter {
|
|||
}
|
||||
}
|
||||
|
||||
#[async_trait::async_trait]
|
||||
impl Filter for ArchiveFilter {
|
||||
type T = Vec<SingleFormat>;
|
||||
type Output = SingleFormatCollection;
|
||||
|
|
|
|||
|
|
@ -113,7 +113,6 @@ pub struct Download {
|
|||
pub(crate) urls: Vec<String>,
|
||||
}
|
||||
|
||||
#[async_trait::async_trait(?Send)]
|
||||
impl Execute for Download {
|
||||
fn pre_check(&mut self) -> Result<()> {
|
||||
if !has_ffmpeg() {
|
||||
|
|
|
|||
|
|
@ -37,7 +37,6 @@ impl DownloadFilter {
|
|||
}
|
||||
}
|
||||
|
||||
#[async_trait::async_trait]
|
||||
impl Filter for DownloadFilter {
|
||||
type T = SingleFormat;
|
||||
type Output = SingleFormatCollection;
|
||||
|
|
|
|||
|
|
@ -24,12 +24,11 @@ pub use download::Download;
|
|||
pub use login::Login;
|
||||
pub use search::Search;
|
||||
|
||||
#[async_trait::async_trait(?Send)]
|
||||
trait Execute {
|
||||
fn pre_check(&mut self) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
async fn execute(mut self, ctx: Context) -> Result<()>;
|
||||
async fn execute(self, ctx: Context) -> Result<()>;
|
||||
}
|
||||
|
||||
#[derive(Debug, Parser)]
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@ pub struct Login {
|
|||
pub remove: bool,
|
||||
}
|
||||
|
||||
#[async_trait::async_trait(?Send)]
|
||||
impl Execute for Login {
|
||||
async fn execute(self, ctx: Context) -> Result<()> {
|
||||
if let Some(login_file_path) = session_file_path() {
|
||||
|
|
|
|||
|
|
@ -100,7 +100,6 @@ pub struct Search {
|
|||
input: String,
|
||||
}
|
||||
|
||||
#[async_trait::async_trait(?Send)]
|
||||
impl Execute for Search {
|
||||
async fn execute(self, ctx: Context) -> Result<()> {
|
||||
let input = if crunchyroll_rs::parse::parse_url(&self.input).is_some() {
|
||||
|
|
|
|||
|
|
@ -3,9 +3,6 @@ use crunchyroll_rs::{
|
|||
Concert, Episode, MediaCollection, Movie, MovieListing, MusicVideo, Season, Series,
|
||||
};
|
||||
|
||||
// Check when https://github.com/dtolnay/async-trait/issues/224 is resolved and update async-trait
|
||||
// to the new fixed version (as this causes some issues)
|
||||
#[async_trait::async_trait]
|
||||
pub trait Filter {
|
||||
type T: Send + Sized;
|
||||
type Output: Send + Sized;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue