Skip to content

Commit

Permalink
golf down rc file reading
Browse files Browse the repository at this point in the history
  • Loading branch information
tenderlove committed Oct 30, 2013
1 parent 9bc99b4 commit 1df1877
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions railties/lib/rails/generators/rails/app/app_generator.rb
Expand Up @@ -363,8 +363,7 @@ def railsrc(argv)
end

def read_rc_file(railsrc)
extra_args_string = File.read(railsrc)
extra_args = extra_args_string.split(/\n+/).map {|l| l.split}.flatten
extra_args = File.readlines(railsrc).flat_map(&:split)
puts "Using #{extra_args.join(" ")} from #{railsrc}"
extra_args
end
Expand Down

0 comments on commit 1df1877

Please sign in to comment.