Wilson, Douglas on Thu, 14 Aug 2003 13:59:44 -0400


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

RE: "How did I live without this?"


I think I've gone overkill on modifying this, but
in case you want, say, field 1 and 2 and the last field,
you can say:
f 1 2 -1 filename(s)

BEGIN {                              
  usage() unless @ARGV;              
  while ($ARGV[0] =~ /^(\+|-)?\d+/) {
    (my $field = shift) =~ s/^+//;   
    $field-- if $field > 0;          
    push @fields, $field;            
  }                                  
  shift if $ARGV[0] = '--';          
}                                    
                                     
print "@F[@fields]";                 
-
**Majordomo list services provided by PANIX <URL:http://www.panix.com>**
**To Unsubscribe, send "unsubscribe phl" to majordomo@lists.pm.org**