diff --git a/railties/lib/rails/generators/app_base.rb b/railties/lib/rails/generators/app_base.rb index c0fcf7d3b49bd53ba041f63c634ce13b7db7ef29..caaaae09e64f875bda27bccb3017c9eb6db935cb 100644 --- a/railties/lib/rails/generators/app_base.rb +++ b/railties/lib/rails/generators/app_base.rb @@ -113,7 +113,6 @@ def gemfile_entries javascript_gemfile_entry, jbuilder_gemfile_entry, sdoc_gemfile_entry, - spring_gemfile_entry, psych_gemfile_entry, @extra_entries].flatten.find_all(&@gem_filter) end @@ -306,12 +305,6 @@ def javascript_runtime_gemfile_entry end end - def spring_gemfile_entry - return [] unless spring_install? - comment = 'Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring' - GemfileEntry.new('spring', nil, comment, group: :development) - end - def psych_gemfile_entry return [] unless defined?(Rubinius) diff --git a/railties/lib/rails/generators/rails/app/templates/Gemfile b/railties/lib/rails/generators/rails/app/templates/Gemfile index 826fb860583f56df7bb83e137170199b78916109..d97be95e2788759f0a28a6aba312bdacbd735188 100644 --- a/railties/lib/rails/generators/rails/app/templates/Gemfile +++ b/railties/lib/rails/generators/rails/app/templates/Gemfile @@ -21,14 +21,23 @@ source 'https://rubygems.org' # Use Capistrano for deployment # gem 'capistrano-rails', group: :development +group :development, :test do <% unless defined?(JRUBY_VERSION) -%> -# To use a debugger + # Call 'debugger' anywhere in the code to stop execution and get a debugger console <%- if RUBY_VERSION < '2.0.0' -%> -# gem 'debugger', group: [:development, :test] + gem 'debugger' <%- else -%> -# gem 'byebug', group: [:development, :test] + gem 'byebug' <%- end -%> + + # Access an IRB console on exceptions page and /console in development + gem 'web-console' +<%- if spring_install? %> + # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring + gem 'spring' <% end -%> +<% end -%> +end <% if RUBY_PLATFORM.match(/bccwin|cygwin|emx|mingw|mswin|wince/) -%> # Windows does not include zoneinfo files, so bundle the tzinfo-data gem