Sha256: 78787382e8466195f84f9be87e9efe59d0c3fe7472ac4b34092760750eb1f3f2
Contents?: true
Size: 550 Bytes
Versions: 3
Compression:
Stored size: 550 Bytes
Contents
require 'pathname' module PRSS class CLI def initialize passkey, output_dir @passkey = passkey @output_dir = Pathname.new(output_dir) raise 'no passkey' unless passkey raise 'no output dir' unless output_dir end def run! output = Fetcher.new(@passkey).output links = Parser.new(output) downloaded = Downloader.new(links).download_to(@output_dir) puts "Downloaded #{downloaded.count} files to #{@output_dir}." puts "Files:", *downloaded unless downloaded.empty? end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
prss-0.0.4 | lib/prss/cli.rb |
prss-0.0.3 | lib/prss/cli.rb |
prss-0.0.2 | lib/prss/cli.rb |