This is not the most elegant solution, but it did only take me five minutes.
The salient part is the backspace and printing blanks bit. A more elegent
solution would figure out how to destructively clear the line using something
from ncurses.
#!/usr/bin/perl -w
$|=1;
@reports = ("starting", "
Paul Harwood wrote:
>
> Is there a simple way to print over an existing line?
>
> For example: I would like to have a progress report that reads 10%, 20%
> etc. I don't want to print a new line each time. I want to write over
> the existing line and have it update as it goes.
Hi Paul.
I presume y
Paul Harwood wrote:
> Is there a simple way to print over an existing line?
>
> For example: I would like to have a progress report that
> reads 10%, 20%
> etc. I don't want to print a new line each time. I want to write over
> the existing line and have it update as it goes.
>
> --Paul
Use "\r"