mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
added Pry.editor option for use by the edit-method command
This commit is contained in:
parent
4fc757ece1
commit
477a25ae21
1 changed files with 6 additions and 0 deletions
|
@ -98,6 +98,11 @@ class Pry
|
|||
# Set to true if the pry-doc extension is loaded.
|
||||
# @return [Boolean]
|
||||
attr_accessor :has_pry_doc
|
||||
|
||||
# The default editor to use. Defaults to $EDITOR or nano if
|
||||
# $EDITOR is not defined.
|
||||
# @return [String]
|
||||
attr_accessor :editor
|
||||
end
|
||||
|
||||
# Load the rc files given in the `Pry::RC_FILES` array.
|
||||
|
@ -216,6 +221,7 @@ class Pry
|
|||
@should_load_rc = true
|
||||
@rc_loaded = false
|
||||
@cli = false
|
||||
@editor = ENV['EDITOR'] ? ENV['EDITOR'] : "nano"
|
||||
end
|
||||
|
||||
self.reset_defaults
|
||||
|
|
Loading…
Reference in a new issue