The testing reports for the approaches listed here (http://search.cpan.org/search?mode=module&query=File%3A%3ATail) do not report success in windows applications.
The environment is ActiveState perl on a windows 7 box. I want to read records into my perl program from a file as they are being written to it by an external program. While windows does not have an internal tail command, MS does provide one as described at this site: ( http://www.windows-commandline.com/2010/08/tail-command-for-windows.html). Upon execution, this works fine except the output from tail goes to a command window and is not capture-able in perl by any means I can develop. I'm seeking an equivalent capability using perl's file IO functions. Thanks;
#! /usr/bin/perl my $cmdtorun = "tail -f D:/prjct/logger/2013-06-05.dlg |"; open(TL, $cmdtorun) || die "Failed: $!\n"; while ( <TL> ) { print "Got: $_\n"; }
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |