Onepiece Manga Zip

Posted on by admin
Embed
download images of one piece manga chapter from kissmanga

One Piece Manga Collage Zip Up Hooide made by Santos Coelho MORE AT SANTOSCOELHO.COM This product is hand made and made on-demand. Xforce keygen autocad 2014 64 bit.

.gitignore
.versions.conf
ruby=ruby-2.1.0
ruby-gemset=one_piece
#ruby-gem-install=bundler rake
#ruby-bundle-install=true
Gemfile
Onepiece Manga Zip
# A sample Gemfile
source 'https://rubygems.org'
gem 'pry'
gem 'nokogiri'
gem 'em-synchrony'
gem 'em-http-request'
Gemfile.lock
One piece manga reader
GEM
remote:https://rubygems.org/
specs:
addressable (2.3.5)
coderay (1.1.0)
cookiejar (0.3.0)
em-http-request (1.1.2)
addressable (>=2.3.4)
cookiejar
em-socksify (>=0.3)
eventmachine (>=1.0.3)
http_parser.rb (>=0.6.0)
em-socksify (0.3.0)
eventmachine (>=1.0.0.beta.4)
em-synchrony (1.0.3)
eventmachine (>=1.0.0.beta.1)
eventmachine (1.0.3)
http_parser.rb (0.6.0)
method_source (0.8.2)
mini_portile (0.5.2)
nokogiri (1.6.1)
mini_portile (~>0.5.0)
pry (0.9.12.4)
coderay (~>1.0)
method_source (~>0.8)
slop (~>3.4)
slop (3.4.7)
PLATFORMS
ruby
DEPENDENCIES
em-http-request
em-synchrony
nokogiri
pry
loader.rb
Zip

One Piece Manga Zip

#!/usr/bin/env ruby
require'bundler/setup'
require'open-uri'
require'rss'
require'fileutils'
require'nokogiri'
require'em-synchrony'
require'em-synchrony/em-http'
RSS_URL='http://kissmanga.com/RSS/Manga/One-Piece'.freeze
DOWNLOAD_BASE='./chapters'
defextract_chapter_image_urlschapter
chapter =Nokogiri::HTML(chapter)
chapter.search('div#divImage img').map{ e e['src']}
end
defget_images_concurrent(urls, concurrency=5)
image_data =nil
EM.synchrony do
# iterator will execute async blocks until completion, .each, .inject also work!
results =EM::Synchrony::Iterator.new(urls, concurrency).map dourl, iter
# fire async requests, on completion advance the iterator
http =EventMachine::HttpRequest.new(url).aget
http.callback { iter.return(http) }
http.errback { iter.return(http) }
end
image_data = results # all completed requests
EventMachine.stop
end
image_data.map{ image
[ image.response,
image.req.path.split('/').last
]
}
end
caseARGV.size
when1
first2load =ARGV.first.to_i
when2
first2load =ARGV[0].to_i
last2load =ARGV[1].to_i
else
p'wtf'
exit1
end
open(RSS_URL) dorss
feed =RSS::Parser.parse(rss)
feed.items.each doitem
number = item.title.match(/d{3}/)[0].to_i
nextif (last2load && number >= last2load)
exitif number < first2load
title = item.title.gsub(/^One Piece /,'')
chapter_path ='#{DOWNLOAD_BASE}/#{title}'
nextifFile.exists?(chapter_path)
FileUtils.mkdir_p(chapter_path)
#open(URI.encode(item.link)) do chapter
# IO.write('#{chapter_path}/images.urls', extract_chapter_image_urls(chapter).join('n'))
#end
open(URI.encode(item.link)) dochapter
images = get_images_concurrent(extract_chapter_image_urls(chapter))
images.each dodata,filename
IO.write('#{chapter_path}/#{filename}', data)
end
end
p'Chapter #{title} downloaded!'
end
end

One Piece Manga Reader

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment