From: RicterZ Date: Wed, 14 Oct 2020 18:09:09 +0000 (+0800) Subject: add default value of output dir X-Git-Tag: 0.4.6~1^2 X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=d84b827241fd00140c30d16081c1aa6275eff2f6;p=nhentai.git add default value of output dir --- diff --git a/nhentai/cmdline.py b/nhentai/cmdline.py index 519279f..2d59309 100644 --- a/nhentai/cmdline.py +++ b/nhentai/cmdline.py @@ -87,7 +87,7 @@ def cmd_parser(): choices=['recent', 'popular', 'popular-today', 'popular-week']) # download options - parser.add_option('--output', '-o', type='string', dest='output_dir', action='store', default='', + parser.add_option('--output', '-o', type='string', dest='output_dir', action='store', default='./', help='output dir') parser.add_option('--threads', '-t', type='int', dest='threads', action='store', default=5, help='thread count for downloading doujinshi') diff --git a/nhentai/command.py b/nhentai/command.py index d0fce3d..47fbc3c 100644 --- a/nhentai/command.py +++ b/nhentai/command.py @@ -94,11 +94,8 @@ def main(): elif options.is_pdf: generate_pdf(options.output_dir, doujinshi, options.rm_origin_dir) - if options.main_viewer and options.output_dir: + if options.main_viewer: generate_main_html(options.output_dir) - elif options.main_viewer: - generate_main_html() - if not platform.system() == 'Windows': logger.log(15, '🍻 All done.')