module Stevedore
Private Class Methods
run(command, expected_outcodes = 0)
click to toggle source
# File lib/stevedore.rb, line 9 def self.run(command, expected_outcodes = 0) output = `#{command}` unless [expected_outcodes].flatten.include?($?.exitstatus) raise CommandLineError, "Error while running #{command}" end output.force_encoding('UTF-8') end