From 548c06e81e3e7a2aceb020c1bb7cc88455f9bed0 Mon Sep 17 00:00:00 2001 From: iaacornus Date: Sun, 5 Jun 2022 11:35:31 +0800 Subject: [PATCH] add message to inform that background video is already downloaded this is when the user give an input to -b parameter even there is already downloaded video. Although feature to be able to store multiple background video is suggested, which I plan to work to --- video_creation/background.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/video_creation/background.py b/video_creation/background.py index 7c4527c..6ad2769 100644 --- a/video_creation/background.py +++ b/video_creation/background.py @@ -28,7 +28,11 @@ def download_background(background): "merge_output_format": "mp4", } - if background is not None or not Path("assets/mp4/background.mp4").is_file(): + background_check = Path("assets/mp4/background.mp4").is_file() + if background is not None or not background_check: + if background_check: + print_substep("Background video is already downloaded! Replacing ...") + try: with YoutubeDL(ydl_opts) as ydl: if background is None: