Lipsiasoft-exception-notifier 1.1 → 1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +7 -2
- data/lib/mailer/exception/exception.html.erb +2 -2
- data/lib/mailer/exception_notifier.rb +1 -1
- metadata +1 -1
data/Rakefile
CHANGED
@@ -4,7 +4,7 @@ require 'rake/rdoctask'
|
|
4
4
|
require 'rake/gempackagetask'
|
5
5
|
|
6
6
|
PKG_NAME = 'exception-notifier'
|
7
|
-
PKG_VERSION = "1.
|
7
|
+
PKG_VERSION = "1.3"
|
8
8
|
PKG_FILE_NAME = "#{PKG_NAME}-#{PKG_VERSION}"
|
9
9
|
|
10
10
|
$LOAD_PATH << File.join(File.dirname(__FILE__), 'lib')
|
@@ -50,9 +50,14 @@ Rake::GemPackageTask.new(spec) do |p|
|
|
50
50
|
end
|
51
51
|
|
52
52
|
desc "Install the gem locally"
|
53
|
-
task :install => [:repackage] do
|
53
|
+
task :install => [:uninstall, :repackage] do
|
54
54
|
sh %{sudo gem install pkg/#{PKG_FILE_NAME}.gem}
|
55
55
|
end
|
56
|
+
|
57
|
+
desc "Unistall the gem from local"
|
58
|
+
task :uninstall => [:clean] do
|
59
|
+
sh %{sudo gem uninstall #{PKG_NAME}}
|
60
|
+
end
|
56
61
|
|
57
62
|
desc "Generate a gemspec file for GitHub"
|
58
63
|
task :gemspec do
|
@@ -1,7 +1,7 @@
|
|
1
1
|
A <%= @exception.class %> occurred in <%= @controller.controller_name %>#<%= @controller.action_name %>:
|
2
2
|
|
3
|
-
|
4
|
-
|
3
|
+
<%=h @exception.message %>
|
4
|
+
<%=h @backtrace.join("\n") %>
|
5
5
|
|
6
6
|
* URL : <%= @request.protocol %><%= @host %><%= @request.request_uri %>
|
7
7
|
* IP address: <%= @request.env["HTTP_X_FORWARDED_FOR"] || @request.env["REMOTE_ADDR"] %>
|
@@ -22,7 +22,7 @@ module Lipsiadmin
|
|
22
22
|
def exception(exception, controller, request)
|
23
23
|
content_type "text/plain"
|
24
24
|
|
25
|
-
subject "#{email_prefix} #{exception.
|
25
|
+
subject "#{email_prefix} A #{exception.class} occurred in #{controller.controller_name}##{controller.action_name}"
|
26
26
|
|
27
27
|
recipients recipients_addresses
|
28
28
|
from sender_address
|