diff --git a/src/dl.rs b/src/dl.rs index c8be4c3..2643cdd 100644 --- a/src/dl.rs +++ b/src/dl.rs @@ -1,3 +1,27 @@ +use self::spawn::SpawnError; +use self::yt_dlp::YtDlpError; + pub mod ffmpeg; mod spawn; pub mod yt_dlp; + +pub enum DownloadError { + Message(String) +} + +impl From for DownloadError { + fn from(value: SpawnError) -> Self { + Self::Message(value.to_string()) + } +} + +impl From for DownloadError { + fn from(value: YtDlpError) -> Self { + Self::Message(value.to_string()) + } +} + +pub async fn download(url: &str) -> Result { + + todo!() +} \ No newline at end of file