Sha256: 9aed792455b6fe6a33acbe7a0b86a5949bc343c02a3c66f3368ced42d439dac0

Contents?: true

Size: 621 Bytes

Versions: 2

Compression:

Stored size: 621 Bytes

Contents

require File.join(File.dirname(__FILE__), 'tvshow')
require "pathname"

class Inspector
  
  attr_accessor :tv_shows
  
  def initialize(path, apikey, options = {})
    @path = Pathname.new(path).realpath.to_s
    
    if options[:wait]
      $stdout.print "Sleep 90\n"
      sleep 90
    end
    
    $stdout.print "Begin searching for new TV Show episodes...\n"
    @tv_shows = TvShow.search(@path, apikey)
  end

  def self.growl(title, msg, pri = 0)
    system("/usr/local/bin/growlnotify -w -n autotvnzb --image #{File.dirname(__FILE__) + "/../asset/failure.png"} -p #{pri} -m #{msg.inspect} #{title} &") 
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
autotvnzb-0.1.1 lib/inspector.rb
autotvnzb-0.1.0 lib/inspector.rb