From 99c726dc2b6fe8f4fd90c9f7f4aa121317e7fc06 Mon Sep 17 00:00:00 2001 From: Nick Zana Date: Fri, 5 May 2023 01:21:13 -0400 Subject: [PATCH] improved accuracy of download success messages --- src/config.rs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/config.rs b/src/config.rs index 6e41145..d269904 100644 --- a/src/config.rs +++ b/src/config.rs @@ -81,10 +81,17 @@ impl Stream { loop { match dl.run_async().await { Ok(YoutubeDlOutput::SingleVideo(video)) => { - println!("Successfully downloading video `{url:#?}`: {video:#?}"); + println!( + "Successfully downloaded {} `{url:#?}`: {video:#?}", + if Some(true) == video.is_live { + "livestream" + } else { + "video" + } + ); } Ok(YoutubeDlOutput::Playlist(playlist)) => { - println!("Successfully downloading playlist `{url:#?}`: {playlist:#?}"); + println!("Successfully downloaded playlist `{url:#?}`: {playlist:#?}"); } Err(e) => { let err = if let youtube_dl::Error::ExitCode { stderr, .. } = e {