aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorgarret <garret@airmail.cc>2023-07-12 17:08:01 +0100
committergarret <garret@airmail.cc>2023-07-13 08:06:22 +0100
commit5c882d09bb963b6d1a3af14168c975361be31c8d (patch)
tree2eb8966990eeab1f85d83f8086d6863d548d1aef
parentd83cc4ef41104abc1b504e49f3dd53f84769c911 (diff)
downloadcomicwalker-dl-5c882d09bb963b6d1a3af14168c975361be31c8d.tar.gz
comicwalker-dl-5c882d09bb963b6d1a3af14168c975361be31c8d.tar.bz2
comicwalker-dl-5c882d09bb963b6d1a3af14168c975361be31c8d.zip
make cid a positional argument
walker.py [the cid] rather than walker.py -cid [the cid]
-rw-r--r--walker.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/walker.py b/walker.py
index f32a6e7..a3d7408 100644
--- a/walker.py
+++ b/walker.py
@@ -8,14 +8,10 @@ import sys
from binascii import unhexlify
parser = argparse.ArgumentParser()
-parser.add_argument('-cid', help='content id, &cid={...}. see url when reading a chapter')
+parser.add_argument('cid', help='content id, &cid={...}. see url when reading a chapter')
parser.add_argument('-v', '--verbose', help='no progressive download logs on terminal', action="store_true")
args = parser.parse_args()
-if args.cid == None:
- parser.print_help()
- sys.exit()
-
logging.basicConfig(format='[%(levelname)s] %(asctime)s: %(message)s', datefmt='%Y-%m-%d %H:%M:%S', level=logging.INFO)
def start(url, headers):