mirror of
https://github.com/StrawberryMaster/wayback-machine-downloader.git
synced 2025-12-18 02:06:35 +00:00
Avoid interleaving status output with file listing.
Before:
[
Getting snapshot pages.. found 1 snaphots to consider.
{"file_url":"http://www.trackpedia.com:80/forums/archive/index.php/f-115.html","timestamp":20131221124252,"file_id":"forums/archive/index.php/f-115.html"},
]
After:
Getting snapshot pages.. found 1 snaphots to consider.
[
{"file_url":"http://www.trackpedia.com:80/forums/archive/index.php/f-115.html","timestamp":20131221124252,"file_id":"forums/archive/index.php/f-115.html"},
]
This commit is contained in:
parent
6b8c1aa194
commit
65b1948517
@ -135,8 +135,11 @@ class WaybackMachineDownloader
|
||||
end
|
||||
|
||||
def list_files
|
||||
# retrieval produces its own output
|
||||
files = get_file_list_by_timestamp
|
||||
# ... hence delay printing the opening bracket
|
||||
puts "["
|
||||
get_file_list_by_timestamp.each do |file|
|
||||
files.each do |file|
|
||||
puts file.to_json + ","
|
||||
end
|
||||
puts "]"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user