Commit 748ea86f authored by Fabio Pelosin's avatar Fabio Pelosin

[ErrorReport] Include exception class

parent 66e926b4
......@@ -7,7 +7,7 @@ module Pod
module UserInterface
module ErrorReport
class << self
def report(error)
def report(exception)
return <<-EOS
#{'――― MARKDOWN TEMPLATE ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――'.reversed}
......@@ -36,16 +36,16 @@ Repositories : #{repo_information.join("\n ")}
### Error
```
#{error.message}
#{error.backtrace.join("\n")}
#{exception.class} - #{exception.message}
#{exception.backtrace.join("\n")}
```
#{'――― TEMPLATE END ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――'.reversed}
#{'[!] Oh no, an error occurred.'.red}
#{error_from_podfile(error)}
#{error_from_podfile(exception)}
#{'Search for existing github issues similar to yours:'.yellow}
#{"https://github.com/CocoaPods/CocoaPods/issues/search?q=#{CGI.escape(error.message)}"}
#{"https://github.com/CocoaPods/CocoaPods/issues/search?q=#{CGI.escape(exception.message)}"}
#{'If none exists, create a ticket, with the template displayed above, on:'.yellow}
https://github.com/CocoaPods/CocoaPods/issues/new
......
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