Skip to content

Instantly share code, notes, and snippets.

View toydestroyer's full-sized avatar
🚨
Technical debt collection

Sergey Toy toydestroyer

🚨
Technical debt collection
View GitHub Profile
@toydestroyer
toydestroyer / nike-wrm15.rb
Created September 18, 2015 18:55
Fetch all photos from Nike #WeRunMoscow 2015
arr = []
1.upto(25000) do |i|
puts "Fetch #{i}"
res = RestClient.get("https://s3.nikecdn.com/rrpcee/wrm15-gallery/#{i}.json")
JSON.parse(res).each do |row|
arr << row["image"]
end
end
arr.uniq!
arr.map! { |item| "https://s3.nikecdn.com/rrpcee/wrm15-gallery/#{item}" }