Skip Menu |

This queue is for tickets about the Term-ReadLine-Gnu CPAN distribution.

Maintainer(s)' notes

When you report a bug, please provide the following information;

- output of
	perl -V
	perl Makefile.PL verbose
	make test TEST_VERBOSE=1
	perl -Mblib t/00checkver.t
	echo $TERM
- terminal emulator which you are using
- compiler which is used to compile the GNU Readline Library (libreadline.a) if you can know.
Read INSTALL in the distribution for more details.

Report information
The Basics
Id: 123777
Status: resolved
Priority: 0/
Queue: Term-ReadLine-Gnu

People
Owner: HAYASHI [...] cpan.org
Requestors: sorm [...] is4u.cz
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: History involves color prompt if used together with Term::ANSIColor on UTF-8 installations
Date: Tue, 28 Nov 2017 15:37:34 +0000
To: "bug-Term-ReadLine-Gnu [...] rt.cpan.org" <bug-Term-ReadLine-Gnu [...] rt.cpan.org>
From: Milan Šorm <sorm [...] is4u.cz>

Message body is not shown because it is too large.

Message body is not shown because it is too large.

You must let the GNU Readline Library know that your command prompt includes non-printing characters. Try follows and let me know the result. use Term::ReadLine; BEGIN { import Term::ReadLine::Gnu qw(:prompt); } ... while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . 'Your command? ' . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) { See the following links also. http://search.cpan.org/dist/Term-ReadLine-Gnu/Gnu.pm#Standard_Methods Show quoted text
> readline(PROMPT[,PREPUT]) > ... > PROMPT may include some escape sequences. Use RL_PROMPT_START_IGNORE to begin a sequence of non-printing characters, and RL_PROMPT_END_IGNORE to end the sequence.
http://search.cpan.org/dist/Term-ReadLine-Gnu/Gnu.pm#EXPORTS Hope this helps.
Sorry I made a mistake; Show quoted text
> while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . 'Your command? ' . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) {
This line should be; Show quoted text
> while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . RL_PROMPT_END_IGNORE . 'Your command? ' . RL_PROMPT_START_IGNORE . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) {
Subject: RE: [rt.cpan.org #123777] History involves color prompt if used together with Term::ANSIColor on UTF-8 installations
Date: Sat, 2 Dec 2017 09:57:13 +0000
To: "bug-Term-ReadLine-Gnu [...] rt.cpan.org" <bug-Term-ReadLine-Gnu [...] rt.cpan.org>
From: Milan Šorm <sorm [...] is4u.cz>
Thanks, I'll check it later today when somebody else from my family take care about my children. It is really impossible to program anything with them around :D Thank you for help. Show quoted text
-----Original Message----- From: Hiroo_HAYASHI via RT [mailto:bug-Term-ReadLine-Gnu@rt.cpan.org] Sent: Saturday, December 2, 2017 9:59 AM To: Milan Šorm <sorm@is4u.cz> Subject: [rt.cpan.org #123777] History involves color prompt if used together with Term::ANSIColor on UTF-8 installations <URL: https://rt.cpan.org/Ticket/Display.html?id=123777 > Sorry I made a mistake;
> while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . 'Your command? ' . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) {
This line should be;
> while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . RL_PROMPT_END_IGNORE . 'Your command? ' . RL_PROMPT_START_IGNORE . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) {
Subject: RE: [rt.cpan.org #123777] History involves color prompt if used together with Term::ANSIColor on UTF-8 installations
Date: Sat, 2 Dec 2017 12:47:08 +0000
To: "bug-Term-ReadLine-Gnu [...] rt.cpan.org" <bug-Term-ReadLine-Gnu [...] rt.cpan.org>
From: Milan Šorm <sorm [...] is4u.cz>
This one helps, thank you. It is now working pretty well :) Milan Show quoted text
-----Original Message----- From: Hiroo_HAYASHI via RT [mailto:bug-Term-ReadLine-Gnu@rt.cpan.org] Sent: Saturday, December 2, 2017 9:21 AM To: Milan Šorm <sorm@is4u.cz> Subject: [rt.cpan.org #123777] History involves color prompt if used together with Term::ANSIColor on UTF-8 installations <URL: https://rt.cpan.org/Ticket/Display.html?id=123777 > You must let the GNU Readline Library know that your command prompt includes non-printing characters. Try follows and let me know the result. use Term::ReadLine; BEGIN { import Term::ReadLine::Gnu qw(:prompt); } ... while ( my $cmd = $readline->readline( RL_PROMPT_START_IGNORE . color( 'yellow' ) . 'Your command? ' . color( 'reset' ) . RL_PROMPT_END_IGNORE ) ) { See the following links also. http://search.cpan.org/dist/Term-ReadLine-Gnu/Gnu.pm#Standard_Methods
> readline(PROMPT[,PREPUT]) > ... > PROMPT may include some escape sequences. Use RL_PROMPT_START_IGNORE to begin a sequence of non-printing characters, and RL_PROMPT_END_IGNORE to end the sequence.
http://search.cpan.org/dist/Term-ReadLine-Gnu/Gnu.pm#EXPORTS Hope this helps.
Hi, Show quoted text
> This one helps, thank you. It is now working pretty well :)
I'm glad to hear that. Enjoy your precious time with children!