[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

using perl's gnu-readline interface, howto 'completion' & 'filter histor

From: Linda Walsh
Subject: using perl's gnu-readline interface, howto 'completion' & 'filter history'?
Date: Fri, 09 Jan 2015 12:33:07 -0800
User-agent: Thunderbird

I have a little calculator interface that I use readline for.
Imagine my surprise when I type 1+<TAB> and get a list of files
to add to 1.  Um... not ideal?

I add a time/date stamp to each line typed in.

In bash when I scroll back, I don't the time
entries, but I do in my calculator.  How can I filter
them out?

In the hist files for bash I see:
ps  -ef|grep fetch
ps  -ef|grep fetch
more /etc/rc.d/ipmi_hw_mond
and in my calc, I see:

use Math::Simple

They look similar, but I don't see why bash suppresses them, but
my calc doesn't.  Is there an option to set in readline?

Note, I do set some options, but seem to need to write the timestamp
into the history file myself.

histfile update writes the time itself to get the time in the .hist file...

       if ($histfile_h) {
printf($histfile_h "#%d\n%s\n", CORE::time,$_) unless $_ eq 'quit';

i.e. the write_timestamps option seems to be having no effect -- unless
it's writing another history file someplace else...?

It may just be the perlmod for this interface is a bit dated as well...but
thought I'd ask here first...


reply via email to

[Prev in Thread] Current Thread [Next in Thread]