diff options
| author | aycabta <aycabta@gmail.com> | 2021-08-30 01:23:20 +0900 |
|---|---|---|
| committer | aycabta <aycabta@gmail.com> | 2021-08-30 02:37:23 +0900 |
| commit | 11b825076b145fec5a27ce1ed0e8e412bd4d857a (patch) | |
| tree | e310a1dffe5d913ba3b0541bea3f60c4de2b2fb0 /lib/reline/line_editor.rb | |
| parent | 60eb328d42b76b09e7e963306d627f8e77890e9f (diff) | |
[ruby/reline] Add config.autocompletion
https://github.com/ruby/reline/commit/3d918e4ccb
Diffstat (limited to 'lib/reline/line_editor.rb')
| -rw-r--r-- | lib/reline/line_editor.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/reline/line_editor.rb b/lib/reline/line_editor.rb index b5a5af30f3..5e3b836037 100644 --- a/lib/reline/line_editor.rb +++ b/lib/reline/line_editor.rb @@ -1426,7 +1426,11 @@ class Reline::LineEditor if result.is_a?(Array) completion_occurs = true process_insert - complete(result) + if @config.autocompletion + move_completed_list(result, :down) + else + complete(result) + end end end elsif not @config.disable_completion and @config.editing_mode_is?(:vi_insert) and ["\C-p".ord, "\C-n".ord].include?(key.char) |
