Skip to content

Instantly share code, notes, and snippets.

@ddrscott
Last active December 22, 2017 09:56
Show Gist options
  • Select an option

  • Save ddrscott/b929cb588df23881e37bf6247568502f to your computer and use it in GitHub Desktop.

Select an option

Save ddrscott/b929cb588df23881e37bf6247568502f to your computer and use it in GitHub Desktop.
Project based Pry history
# append to ~/.pryrc
local_pry_history = File.join(Dir.pwd, '.pry_history')
if File.file? local_pry_history
puts("\e[33mUsing local Pry history:\e[0m #{local_pry_history}")
Pry.config.history.file = local_pry_history
end
# ## Add a `.pry_history` to project directory:
#
# cd path/to/project
# touch .pry_history
#
# ## Append to `.gitignore`:
#
# .pry_history
#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment