Module: Thor::LineEditor
- Defined in:
- lib/thor/line_editor.rb,
lib/thor/line_editor/basic.rb,
lib/thor/line_editor/readline.rb
Defined Under Namespace
Class Method Summary collapse
Class Method Details
.best_available ⇒ Object
10 11 12 13 14 15 |
# File 'lib/thor/line_editor.rb', line 10 def self.best_available [ Thor::LineEditor::Readline, Thor::LineEditor::Basic ].detect(&:available?) end |
.readline(prompt, options = {}) ⇒ Object
6 7 8 |
# File 'lib/thor/line_editor.rb', line 6 def self.readline(prompt, = {}) best_available.new(prompt, ).readline end |