read_history_range#

Load lines from a history file into memory. Reads the whole file by default, or lines $from..$to when given.

Synopsis#

$term->ReadHistory;                        # default file, full range
$term->ReadHistory('~/.myhist', 100, -1);  # last hundred-odd lines

Passing undef for $filename reads from ~/.history. $to = -1 means “to the end”. Returns 0 on success, a non-zero errno on failure.