Skip to content

Commit

Permalink
fixed rails-console history dumping by @prioux
Browse files Browse the repository at this point in the history
  • Loading branch information
gkiar committed Sep 20, 2017
1 parent 1d47903 commit c0c8675
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion BrainPortal/config/initializers/initialize_console.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,8 @@
#=================================================================

if defined?(Rails::Console)
IRB.conf[:RC_NAME_GENERATOR] = lambda { |ext| (Rails.root + "config/console_rc/init_rc.rb").to_s }
IRB.conf[:RC_NAME_GENERATOR] = lambda do |ext|
ext.to_s == '_history' ? (ENV['HOME'] + '/.irb-history')
: (Rails.root + "config/console_rc/init_rc.rb").to_s
end
end

0 comments on commit c0c8675

Please sign in to comment.