Skip to content

Instantly share code, notes, and snippets.

@maveonair
Created September 3, 2013 07:21
Show Gist options
  • Save maveonair/6420652 to your computer and use it in GitHub Desktop.
Save maveonair/6420652 to your computer and use it in GitHub Desktop.
Sometimes it is not possible to add the pry-rails gem to a rails project. For this reason a starting the rails console with pry and execute the following ruby code:
# start rails console first:
# bundle exec pry -r ./config/environment
require rails
require 'rails/console/app'
require 'rails/console/helpers'
extend Rails::ConsoleMethods
ActiveRecord::Base.logger = Logger.new(STDOUT)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment