Module: Rudy::SCM::ObjectBase

Included in:
GIT
Defined in:
lib/rudy/scm.rb

Instance Method Summary collapse

Instance Method Details

#execute_rbox_command(ret = nil, &command) ⇒ Object

copied from routines/helper.rb



39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# File 'lib/rudy/scm.rb', line 39

def execute_rbox_command(ret=nil, &command)
  begin
    ret = command.call
    puts '  ' << ret.stdout.join("#{$/}  ") if !ret.stdout.empty?
    print_response(ret)
  rescue Rye::CommandError => ex
    print_response(ex)
    exit 12 unless keep_going?
  rescue Rye::CommandNotFound => ex
    STDERR.puts "  CommandNotFound: #{ex.message}".color(:red)
    STDERR.puts ex.backtrace
    exit 12 unless keep_going?
  end

  ret
end

#raise_early_exceptionsObject



36
# File 'lib/rudy/scm.rb', line 36

def raise_early_exceptions; raise "override raise_early_exceptions"; end