Sha256: 5045549fe28e4fec723beed3708c5eeb34cd11234b07dc28e0b8d5eea2d38d49

Contents?: true

Size: 627 Bytes

Versions: 11

Compression:

Stored size: 627 Bytes

Contents

recipe :application_controller do
  description 'This will add ApplicationController with 404 and 500 errors handling'
  after :assets

  silently do
    remove_file 'app/controllers/application_controller.rb', :verbose => true
    copy_file   'application_controller.rb', 'app/controllers/application_controller.rb'
    empty_directory "app/views/application"
    copy_file "internal_error.html.erb", "app/views/application/internal_error.html.erb"
    copy_file "not_found.html.erb", "app/views/application/not_found.html.erb"

    # To catch routing errors
    route 'match "*catch_all" => "application#not_found"'
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
playmo-0.1.10 recipes/application_controller_recipe.rb
playmo-0.1.9 recipes/application_controller_recipe.rb
playmo-0.1.8 recipes/application_controller_recipe.rb
playmo-0.1.7 recipes/application_controller_recipe.rb
playmo-0.1.6 recipes/application_controller_recipe.rb
playmo-0.1.5 recipes/application_controller_recipe.rb
playmo-0.1.4 recipes/application_controller_recipe.rb
playmo-0.1.3 recipes/application_controller_recipe.rb
playmo-0.1.2 recipes/application_controller_recipe.rb
playmo-0.1.1 lib/playmo/recipes/application_controller_recipe.rb
playmo-0.1.0 lib/playmo/recipes/application_controller_recipe.rb