I'm looking to create an interactive console application with Perl. What I'm really looking for is something similar to a less screen, but where a user could input commands to perform certain functions, and where output could continually be updated on their screen. For instance, they might want to filter the output by pressing "f" and typing in a regex. They might wish to manipulate or filter the output in other ways.
A simple example would be printing information to the screen, and updating it every 5 seconds. I've seen other users emulated this by clearing the console and re-printing the information. What I don't like about this, is that all it does is scroll x amount of blank lines down and re-print the information. So that if you looked at the command prompt history, you would see the information printed and a bunch of blank lines many, many times.
If possible I want it to be like less, where it opens up an interactive screen, yet once the user quits the command prompt history does not show anything. In other words the information stayed exclusively in the less session, and there was no trace of it once the user quit the program. Please let me know if there is a way to do this, or even a module.
Thanks!
In reply to Interactive "Less Screen" Possible? by bigbot
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |