diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index 23e71e0585..7faabbae6c 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -184,6 +184,7 @@ protected end end unless $? == 0 + puts "Exit code: #{$?}" puts out raise end diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb index 2a8dff0023..7beaba8ad3 100644 --- a/Library/Homebrew/utils.rb +++ b/Library/Homebrew/utils.rb @@ -69,7 +69,10 @@ def safe_system cmd, *args # CTRL-C interrupt to us too, so execution continues, but the exit code os # still 2 so we raise our own interrupt raise Interrupt, cmd if $?.termsig == 2 - raise ExecutionError.new(cmd, args) unless exec_success and $?.success? + unless exec_success and $?.success? + puts "Exit code: #{$?}" + raise ExecutionError.new(cmd, args) + end end def curl url, *args