summaryrefslogtreecommitdiff
path: root/lib/highline/terminal.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/highline/terminal.rb')
-rwxr-xr-xlib/highline/terminal.rb8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/highline/terminal.rb b/lib/highline/terminal.rb
index cd1d3dc..d736369 100755
--- a/lib/highline/terminal.rb
+++ b/lib/highline/terminal.rb
@@ -98,9 +98,7 @@ class HighLine
def get_line_with_readline(question, highline)
require "readline" # load only if needed
- question_string = highline.render_statement(question)
-
- raw_answer = readline_read(question_string, question)
+ raw_answer = readline_read(question)
if !raw_answer && highline.track_eof?
raise EOFError, "The input stream is exhausted."
@@ -113,7 +111,7 @@ class HighLine
# @param prompt [String] Readline prompt
# @param question [HighLine::Question] question from where to get
# autocomplete candidate strings
- def readline_read(prompt, question)
+ def readline_read(question)
# prep auto-completion
unless question.selection.empty?
Readline.completion_proc = lambda do |str|
@@ -126,7 +124,7 @@ class HighLine
$VERBOSE = nil
raw_answer = run_preserving_stty do
- Readline.readline(prompt, true)
+ Readline.readline("", true)
end
$VERBOSE = old_verbose