Sha256: 96ff4eb099dd8661600b77fe794bfe54a8ce9cf51f3a4c3b89c8ebf61a88cb0e

Contents?: true

Size: 337 Bytes

Versions: 8

Compression:

Stored size: 337 Bytes

Contents

require './lib/media_wiki'

config = MediaWiki::Config.new ARGV 

mw = MediaWiki::Gateway.new(config.url, { :loglevel => Logger::DEBUG } )
mw.login(config.user, config.pw)
ARGF.readlines.each do |image|
  image.strip!
  unless File.exist? image
    File.open(image, 'w') do |file|
      file.write(mw.download(image))
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mediawiki-gateway-0.6.2 samples/download_batch.rb
mediawiki-gateway-0.6.1 samples/download_batch.rb
mediawiki-gateway-0.6.0 samples/download_batch.rb
mediawiki-gateway-0.5.2 samples/download_batch.rb
mediawiki-gateway-0.5.1 script/download_batch.rb
mediawiki-gateway-0.5.0 script/download_batch.rb
mediawiki-gateway-0.4.5 script/download_batch.rb
mediawiki-gateway-0.4.4 script/download_batch.rb