From e65e16d37b1a5d5a0316ef3b23e765a578823be6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Kucharczyk?= Date: Thu, 24 Jun 2021 23:21:36 +0200 Subject: [PATCH] Add basic arguments --destination --chapter-start --notify --- src/manga-up/manga-up.py | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/src/manga-up/manga-up.py b/src/manga-up/manga-up.py index 46be359..6733cec 100644 --- a/src/manga-up/manga-up.py +++ b/src/manga-up/manga-up.py @@ -1,4 +1,21 @@ -import requests +""" +Manga checker and downloader +""" -response = requests.get('https://httpbin.org/ip') -print('Code is {0}.'.format(response.status_code)) \ No newline at end of file +import argparse + +if __name__ == '__main__': + parser = argparse.ArgumentParser( + description="Check for manga updates and download them." + ) + parser.add_argument( + '-d', '--destination', type=str, required=True, help="Target destination where the download file should be saved." + ) + parser.add_argument( + '-s', '--chapter-start', type=int, default=1, help="From which chapter should the program check." + ) + parser.add_argument( + '-n', '--notify', type=str, default=None, help="Apprise notification string." + ) + +args = parser.parse_args() \ No newline at end of file