summaryrefslogtreecommitdiffstats
path: root/4grab.py
diff options
context:
space:
mode:
authorGravatar ryuslash2010-02-12 00:04:34 +0100
committerGravatar ryuslash2010-02-12 00:04:34 +0100
commit5516dbbcae07b9623565c9dc8f06267b3357366e (patch)
tree199d2f5721c90ae9fc11cb6d9696440cc91e3ccd /4grab.py
parentc85a69a893f554f5ab9ffb348e05d9e966d44db9 (diff)
download4grab-5516dbbcae07b9623565c9dc8f06267b3357366e.tar.gz
4grab-5516dbbcae07b9623565c9dc8f06267b3357366e.zip
Stopped saying Failed and Skipped things
Now it summarizes at the end
Diffstat (limited to '4grab.py')
-rwxr-xr-x4grab.py18
1 files changed, 15 insertions, 3 deletions
diff --git a/4grab.py b/4grab.py
index c3e2358..ae550b4 100755
--- a/4grab.py
+++ b/4grab.py
@@ -54,7 +54,11 @@ def walk_with_wizard(baseurl):
t = download.get_thread_links(baseurl)
t = download.get_image_links(baseurl, t)
- download.get_images(t)
+ (skipped, failed, downloaded, total) = download.get_images(t)
+ print "Downloaded: ", downloaded
+ print "Skipped: ", skipped
+ print "Failed: ", failed
+ print "Total: ", total
parser.set_usage(
"""%prog [options]
@@ -97,7 +101,11 @@ elif options.thread:
else:
print "if THREAD is not an absolute URL, CATEGORY must also be specified"
exit(1)
- download.get_images(t)
+ (skipped, failed, downloaded, total) = download.get_images(t)
+ print "Downloaded: ", downloaded
+ print "Skipped: ", skipped
+ print "Failed: ", failed
+ print "Total: ", total
exit(0)
elif options.tempcat:
config.Configuration().set_category(options.tempcat)
@@ -106,4 +114,8 @@ base_url = "%s%s/" % (base_url, config.Configuration().get_category())
t = download.get_thread_links(base_url)
t = download.get_image_links(base_url, t)
-download.get_images(t)
+(skipped, failed, downloaded, total) = download.get_images(t)
+print "Downloaded: ", downloaded
+print "Skipped: ", skipped
+print "Failed: ", failed
+print "Total: ", total