From d0bf25e0cb81888a0e42a072b652a771db8ee4fc Mon Sep 17 00:00:00 2001 From: Kosuke Asami Date: Wed, 17 Jul 2013 18:35:33 +0900 Subject: Let Term::ReadLine::Perl5 output compatible with Term::ReadLine::Gnu --- lib/Reply/Plugin/ReadLine.pm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/Reply/Plugin/ReadLine.pm b/lib/Reply/Plugin/ReadLine.pm index bea2712..18c944b 100644 --- a/lib/Reply/Plugin/ReadLine.pm +++ b/lib/Reply/Plugin/ReadLine.pm @@ -46,6 +46,11 @@ sub new { $history ); + if ($self->{term}->ReadLine eq 'Term::ReadLine::Perl5') { + # output compatible with Term::ReadLine::Gnu + $readline::rl_scroll_nextline = 0; + } + if ($self->{term}->ReadLine eq ('Term::ReadLine::Gnu' or 'Term::ReadLine::Perl5')) { $self->{term}->StifleHistory($opts{history_length}) if defined $opts{history_length} && $opts{history_length} >= 0; -- cgit v1.2.3-54-g00ecf