class RBT::FeedbackBinariesOf

Constants

NAMESPACE
#

NAMESPACE

#

Public Class Methods

new( i = 'ruby', run_already = true ) click to toggle source
#

initialize

#
Calls superclass method RBT::Base::new
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 26
def initialize(
    i           = 'ruby',
    run_already = true
  )
  super()
  reset
  set_input(i)
  run if run_already
end

Public Instance Methods

binaries?() click to toggle source
#

binaries?

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 69
def binaries?
  @binaries
end
input?() click to toggle source
#

input?

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 55
def input?
  @input
end
Also aliased as: search_term?
obtain_dataset() click to toggle source
#

obtain_dataset

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 62
def obtain_dataset
  @dataset = RBT::Cookbooks::Cookbook.new(input?) { :bypass_menu_check }
end
report_binaries() click to toggle source
#

report_binaries

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 76
def report_binaries
  if binaries?.empty?
    opnn; e 'We do not know whether `'+sfancy(search_term?)+
            '` will install any binaries.'
  else
    @binaries.each {|entry|
      e '  - '+entry
    }
  end
end
reset() click to toggle source
#

reset

#
Calls superclass method RBT::Base#reset
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 39
def reset
  super()
  @namespace = NAMESPACE
end
run() click to toggle source
#

run

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 90
def run
  obtain_dataset
  @binaries = @dataset.binaries
  report_binaries
end
search_term?()
Alias for: input?
set_input(i) click to toggle source
#

set_input

#
# File lib/rbt/utility_scripts/feedback_binaries_of.rb, line 47
def set_input(i)
  i = i.join(' ').strip if i.is_a? Array
  @input = i
end