class Bnm::Init

Attributes

artists[RW]

Public Class Methods

new() click to toggle source
# File lib/bnm/init.rb, line 7
def initialize
  @artists = Array.new
end

Public Instance Methods

call() click to toggle source
# File lib/bnm/init.rb, line 11
def call

  # INITIATES SPINNER
  thr = Thread.new do
    while true
      Bnm::Spinner.loading
    end
  end

  # SCRAPING URIS AND ARTISTS
  @artists = Bnm::Scrape.init_scrape(@@url)
  Bnm::Scrape.deep_scrape(@artists)
  Bnm::API.itunes(@artists)

  # KILLS SPINNER AND CLEARS FROM SCREEN
  Thread.kill(thr)
  print "\r"

  # PRINTS OUT DYNAMIC CLI
  Bnm::CLI.launch(@artists)
end