💄 Added ASCII art logo

This commit is contained in:
2021-04-10 23:37:04 +03:00
parent ac2707b506
commit 20625b4177
2 changed files with 16 additions and 2 deletions

View File

@@ -7,6 +7,7 @@ import argparse
from getch import getch from getch import getch
import youtube_dl import youtube_dl
from get_channels import retrieve_youtube_subscriptions from get_channels import retrieve_youtube_subscriptions
from print_logo import print_logo
parser = argparse.ArgumentParser() parser = argparse.ArgumentParser()
parser.add_argument('-i', '--input', action='store', type=str, parser.add_argument('-i', '--input', action='store', type=str,
@@ -27,6 +28,8 @@ ydl_opts = {
'format': 'best' 'format': 'best'
} }
print_logo()
if json_input: if json_input:
f = open(json_input, "r", encoding='utf-8') f = open(json_input, "r", encoding='utf-8')
all_channels = json.loads(f.read()) all_channels = json.loads(f.read())
@@ -34,8 +37,7 @@ if json_input:
else: else:
all_channels = retrieve_youtube_subscriptions() all_channels = retrieve_youtube_subscriptions()
curr_channel = 0 curr_channel = 0
c.print(f'You will be prompted if you want to download \ c.print(f'You will be prompted if you want to download a channel for each of your subscriptions. (total {len(all_channels)})', style='bold')
a channel for each of your subscriptions. (total {len(all_channels)})')
for ch in all_channels: for ch in all_channels:
if download_all: if download_all:
ch['download'] = True ch['download'] = True

12
print_logo.py Normal file
View File

@@ -0,0 +1,12 @@
from rich.console import Console
c = Console()
def print_logo():
c.print("""\
__ ______ __ __________ ______ ______ __________ __
\ \/ / __ \/ / / /_ __/ / / / __ )/ ____/ / ____/ __ \/ /
\ / / / / / / / / / / / / / __ / __/______/ / / / / / /
/ / /_/ / /_/ / / / / /_/ / /_/ / /__/_____/ /___/ /_/ / /___
/_/\____/\____/ /_/ \____/_____/_____/ \____/_____/_____/
""", style='magenta')