Next | Trivial Utilities | 38 |
#!/usr/bin/perl
$| = 1; if ($ARGV[0] eq '-e') { shift; $END++ } my $file = shift;
I didn't bother with Getopt::Std or getopts.pl here
For a program with one option, this is enough
my $devino = "";
As you know, Unix files have ID numbers called i-numbers
When combined with the disk device numbers, these are unique
No two files will have the same device number / i-number pair
$devino is the ID pair for the file ftail thinks it's reading
If the $devino for the file changes, then ftail is no longer reading the right file
Next | Menu | Copyright © 2012 M. J. Dominus |