From f726c79d7489c09615b37f74eb747cf64876a643 Mon Sep 17 00:00:00 2001 From: aycabta Date: Mon, 20 Sep 2021 23:44:01 +0900 Subject: [ruby/reline] Add aliases {prev,next}_history to ed_{prev,next}_history https://github.com/ruby/reline/commit/d740e18cff --- lib/reline/line_editor.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/reline/line_editor.rb') diff --git a/lib/reline/line_editor.rb b/lib/reline/line_editor.rb index 65551035b7..c7d6ff4447 100644 --- a/lib/reline/line_editor.rb +++ b/lib/reline/line_editor.rb @@ -2409,6 +2409,7 @@ class Reline::LineEditor arg -= 1 ed_prev_history(key, arg: arg) if arg > 0 end + alias_method :previous_history, :ed_prev_history private def ed_next_history(key, arg: 1) if @is_multiline and @line_index < (@buffer_of_lines.size - 1) @@ -2456,6 +2457,7 @@ class Reline::LineEditor arg -= 1 ed_next_history(key, arg: arg) if arg > 0 end + alias_method :next_history, :ed_next_history private def ed_newline(key) process_insert(force: true) -- cgit v1.2.3