Class: Warder::Runner

Inherits:
Object
  • Object
show all
Defined in:
lib/warder/runner.rb

Overview

abstract class for command runners

Constant Summary collapse

SCORE =
30

Instance Method Summary collapse

Instance Method Details

#performObject



6
7
8
9
10
11
12
13
14
15
# File 'lib/warder/runner.rb', line 6

def perform
  puts "executing '#{command}'\n"
  code = 0
  IO.popen(command).each do |line|
    print line

    code = 1 if failed?(line)
  end
  code
end