Method: Gitrob::CLI::ProgressBar#initialize

Defined in:
lib/gitrob/cli/progress_bar.rb

#initialize(message, options = {}) ⇒ ProgressBar

Returns a new instance of ProgressBar.



4
5
6
7
8
9
10
11
12
13
14
# File 'lib/gitrob/cli/progress_bar.rb', line 4

def initialize(message, options={})
  @options = {
    :format =>
      "#{'[*]'.light_blue} %t %c/%C %B %j% %e",
    :progress_mark => "|".light_blue,
    :remainder_mark => "|"
  }.merge(options)
  @mutex = Mutex.new
  Gitrob::CLI.info(message)
  @progress_bar = ::ProgressBar.create(@options)
end