in reply to Long download progress report

Something like this (totally untested) code might work for you assuming that the progress reporting on teh remote computer is output to either stdout or stderr:

use threads; my $fh; my $pid; async { $pid = open $fh, "scp dvader@empire.gov:file1.txt dvader@deathstar.com:somedir +2>&1 |" or die $!; }->detach; while( <$fh> ) { print; } close $fh; kill 'quit', $pid;

This runs the command asynchronously through a forking open, redirects all the output to a pipe and then displays the output on the screen.

Note: I've never used scp, so the syntax and indeed the whole idea is just speculation.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."