From ec6aa17a07f40f76ed2b81114a5398376bed6cec Mon Sep 17 00:00:00 2001 From: hartator Date: Fri, 23 Sep 2016 18:19:37 -0700 Subject: [PATCH] Add option to set the maximum number of snapshot pages to consider --- bin/wayback_machine_downloader | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/wayback_machine_downloader b/bin/wayback_machine_downloader index 9607134..af75e71 100755 --- a/bin/wayback_machine_downloader +++ b/bin/wayback_machine_downloader @@ -42,7 +42,11 @@ option_parser = OptionParser.new do |opts| options[:threads_count] = t end - opts.on("-l", "--list", "Only list file urls in a JSON format with the archived timestamps. Won't download anything.") do |t| + opts.on("-p", "--maximum-snapshot NUMBER", Integer, "Maximum snapshot pages to consider (Default is 100)\n\t\t\t\t Count an average of 150,000 snapshots per page ") do |t| + options[:maximum_pages] = t + end + + opts.on("-l", "--list", "Only list file urls in a JSON format with the archived timestamps, won't download anything.") do |t| options[:list] = true end