Skip to content

Commit

Permalink
added erb template
Browse files Browse the repository at this point in the history
  • Loading branch information
fschwahn committed Sep 19, 2011
1 parent bde64f4 commit 77c5f99
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ group :development do
gem "bundler", "~> 1.0.0"
gem "jeweler", "~> 1.6.0"
gem "rcov", ">= 0"
gem 'haml'
end

group :test do
Expand All @@ -23,4 +24,3 @@ group :test do
gem 'bson_ext'
end

gem 'haml'
14 changes: 14 additions & 0 deletions app/views/errship/standard.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<% content_for :head do %>
<%= stylesheet_link_tag 'errship', :media => 'screen, projection' %>
<% end %>

<div class='errship'>
<h1 class='error_code'><%= status_code %></h1>
<% if errship_scope %>
<h2><%= t "errship.#{status_code}.#{errship_scope}.title" %></h2>
<p><%= t "errship.#{status_code}.#{errship_scope}.description" %></p>
<% else %>
<h2><%= t "errship.#{status_code}.title" %></h2>
<p><%= t "errship.#{status_code}.description" %></p>
<% end %>
</div>
11 changes: 6 additions & 5 deletions errship.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Gem::Specification.new do |s|

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = [%q{Logan Koester}, %q{Matthew Wilson}, %q{David Czarnecki}]
s.date = %q{2011-09-03}
s.date = %q{2011-09-19}
s.description = %q{Errship is a Rails 3.1 engine for rendering error pages inside your layout. It supports i18n, custom exceptions, and Airbrake (Hoptoad) error tracking.}
s.email = [%q{[email protected]}, %q{[email protected]}, %q{[email protected]}]
s.extra_rdoc_files = [
Expand All @@ -19,6 +19,7 @@ Gem::Specification.new do |s|
s.files = [
"app/assets/javascripts/application.js",
"app/assets/stylesheets/errship.css",
"app/views/errship/standard.html.erb",
"app/views/errship/standard.html.haml",
"config/locales/en.yml",
"config/routes.rb",
Expand All @@ -30,34 +31,34 @@ Gem::Specification.new do |s|
s.homepage = %q{https://github.com/agoragames/errship}
s.licenses = [%q{MIT}]
s.require_paths = [%q{lib}]
s.rubygems_version = %q{1.8.6}
s.rubygems_version = %q{1.8.9}
s.summary = %q{Errship is a Rails 3.1 engine for rendering error pages inside your layout.}

if s.respond_to? :specification_version then
s.specification_version = 3

if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
s.add_runtime_dependency(%q<haml>, [">= 0"])
s.add_development_dependency(%q<rake>, ["= 0.8.7"])
s.add_development_dependency(%q<shoulda>, [">= 0"])
s.add_development_dependency(%q<bundler>, ["~> 1.0.0"])
s.add_development_dependency(%q<jeweler>, ["~> 1.6.0"])
s.add_development_dependency(%q<rcov>, [">= 0"])
s.add_development_dependency(%q<haml>, [">= 0"])
else
s.add_dependency(%q<haml>, [">= 0"])
s.add_dependency(%q<rake>, ["= 0.8.7"])
s.add_dependency(%q<shoulda>, [">= 0"])
s.add_dependency(%q<bundler>, ["~> 1.0.0"])
s.add_dependency(%q<jeweler>, ["~> 1.6.0"])
s.add_dependency(%q<rcov>, [">= 0"])
s.add_dependency(%q<haml>, [">= 0"])
end
else
s.add_dependency(%q<haml>, [">= 0"])
s.add_dependency(%q<rake>, ["= 0.8.7"])
s.add_dependency(%q<shoulda>, [">= 0"])
s.add_dependency(%q<bundler>, ["~> 1.0.0"])
s.add_dependency(%q<jeweler>, ["~> 1.6.0"])
s.add_dependency(%q<rcov>, [">= 0"])
s.add_dependency(%q<haml>, [">= 0"])
end
end

5 changes: 4 additions & 1 deletion lib/errship.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
require 'haml'
begin
require 'haml'
rescue LoadError
end
require 'rescuers/active_record'
require 'rescuers/mongoid'
require 'rescuers/mongo_mapper'
Expand Down

0 comments on commit 77c5f99

Please sign in to comment.