Help for this page

Select Code to Download


  1. or download this
     use File::stat;
     $st = stat($file) or die "No $file: $!";
     if ( ($st->mode & 0111) && $st->nlink > 1) ) {
         print "$file is executable with lotsa links\n";
     }
    
  2. or download this
    my @listfiles=`ls -l ./`;
    foreach(@listfiles) {
            chomp;
    ...
            my @details = split(/\t/, $_);
            print "$details[-1]: $details[0]\n";
    }