diff options
author | Matthew Draper <matthew@trebex.net> | 2015-04-03 23:07:55 +1030 |
---|---|---|
committer | Matthew Draper <matthew@trebex.net> | 2015-04-03 23:07:55 +1030 |
commit | faa37c76521f954c75cd18ea8f9e736c304fdb68 (patch) | |
tree | d43a0b5a44d450c61ae71e5681889298f33ec863 /railties/lib/rails | |
parent | ca14f11b07cf7ae672cf60f10810c4511d096683 (diff) | |
parent | 2a5bb9d56e785e8b8f70c24621d469c473c9061a (diff) | |
download | rails-faa37c76521f954c75cd18ea8f9e736c304fdb68.tar.gz rails-faa37c76521f954c75cd18ea8f9e736c304fdb68.tar.bz2 rails-faa37c76521f954c75cd18ea8f9e736c304fdb68.zip |
Merge pull request #19429 from mxhold/print_bundle_install_output_line_by_line
Print `bundle install` output in `rails new` as soon as it's available
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators/app_base.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/railties/lib/rails/generators/app_base.rb b/railties/lib/rails/generators/app_base.rb index 813f8b21fd..10deeb0ba2 100644 --- a/railties/lib/rails/generators/app_base.rb +++ b/railties/lib/rails/generators/app_base.rb @@ -315,10 +315,6 @@ module Rails # its own vendored Thor, which could be a different version. Running both # things in the same process is a recipe for a night with paracetamol. # - # We use backticks and #print here instead of vanilla #system because it - # is easier to silence stdout in the existing test suite this way. The - # end-user gets the bundler commands called anyway, so no big deal. - # # We unset temporary bundler variables to load proper bundler and Gemfile. # # Thanks to James Tucker for the Gem tricks involved in this call. @@ -326,8 +322,12 @@ module Rails require 'bundler' Bundler.with_clean_env do - output = `"#{Gem.ruby}" "#{_bundle_command}" #{command}` - print output unless options[:quiet] + full_command = %Q["#{Gem.ruby}" "#{_bundle_command}" #{command}] + if options[:quiet] + system(full_command, out: File::NULL) + else + system(full_command) + end end end |