Commit 189917d7 authored by Fabio Pelosin's avatar Fabio Pelosin

[Command] Don't print error report in development environments

parent 419b21d6
......@@ -37,13 +37,17 @@ module Pod
UI.print_warnings
end
def self.report_error(error)
if error.is_a?(Interrupt)
def self.report_error(exception)
if exception.is_a?(Interrupt)
puts "[!] Cancelled".red
Config.instance.verbose? ? raise : exit(1)
else
puts UI::ErrorReport.report(error)
if ENV['COCOA_PODS_ENV'] != 'development'
puts UI::ErrorReport.report(exception)
exit 1
else
raise exception
end
end
end
......@@ -54,7 +58,7 @@ module Pod
#
# @todo Move silent flag to CLAide.
#
# @note It is importat that the commadnds don't overide the default
# @note It is important that the commands don't override the default
# settings if their flag is missing (i.e. their value is nil)
#
def initialize(argv)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment