adds letter_opener

This commit is contained in:
Juanjo Bazán
2015-07-31 13:51:31 +02:00
parent 627616d9ff
commit e2f7b9c505
4 changed files with 17 additions and 2 deletions

View File

@@ -41,10 +41,8 @@ gem 'ckeditor'
group :development, :test do group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console # Call 'byebug' anywhere in the code to stop execution and get a debugger console
gem 'byebug' gem 'byebug'
# Access an IRB console on exception pages or by using <%= console %> in views # Access an IRB console on exception pages or by using <%= console %> in views
gem 'web-console', '~> 2.0' gem 'web-console', '~> 2.0'
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
gem 'spring' gem 'spring'
gem 'rspec-rails', '~> 3.0' gem 'rspec-rails', '~> 3.0'
@@ -52,6 +50,7 @@ group :development, :test do
gem 'factory_girl_rails' gem 'factory_girl_rails'
gem 'launchy' gem 'launchy'
gem 'quiet_assets' gem 'quiet_assets'
gem 'letter_opener_web', '~> 1.2.0'
end end
group :test do group :test do

View File

@@ -108,6 +108,11 @@ GEM
json (1.8.3) json (1.8.3)
launchy (2.4.3) launchy (2.4.3)
addressable (~> 2.3) addressable (~> 2.3)
letter_opener (1.4.1)
launchy (~> 2.2)
letter_opener_web (1.2.3)
letter_opener (~> 1.0)
rails (>= 3.2)
loofah (2.0.2) loofah (2.0.2)
nokogiri (>= 1.5.9) nokogiri (>= 1.5.9)
mail (2.6.3) mail (2.6.3)
@@ -234,6 +239,7 @@ DEPENDENCIES
jbuilder (~> 2.0) jbuilder (~> 2.0)
jquery-rails jquery-rails
launchy launchy
letter_opener_web (~> 1.2.0)
pg pg
poltergeist poltergeist
quiet_assets quiet_assets
@@ -247,3 +253,6 @@ DEPENDENCIES
turbolinks turbolinks
uglifier (>= 1.3.0) uglifier (>= 1.3.0)
web-console (~> 2.0) web-console (~> 2.0)
BUNDLED WITH
1.10.5

View File

@@ -17,6 +17,9 @@ Rails.application.configure do
config.action_mailer.raise_delivery_errors = false config.action_mailer.raise_delivery_errors = false
config.action_mailer.default_url_options = { host: 'localhost', port: 3000 } config.action_mailer.default_url_options = { host: 'localhost', port: 3000 }
# Deliver emails to a development mailbox at /letter_opener
config.action_mailer.delivery_method = :letter_opener
# Print deprecation notices to the Rails logger. # Print deprecation notices to the Rails logger.
config.active_support.deprecation = :log config.active_support.deprecation = :log

View File

@@ -61,4 +61,8 @@ Rails.application.routes.draw do
# # (app/controllers/admin/products_controller.rb) # # (app/controllers/admin/products_controller.rb)
# resources :products # resources :products
# end # end
if Rails.env.development?
mount LetterOpenerWeb::Engine, at: "/letter_opener"
end
end end