I have the following error:
ls -lt | awk 'BEGIN NR > 1 { print $2, $9 }'
Syntax Error The source line is 1.
The error context is
BEGIN >>> NR <<< > 1 { print $2, $9 }
awk: 0602-500 Quitting The source line is 1.
What I want to do is ls a directory, skip the first line, then $2 will determine if the file is linked and $9 is the file name. I want to be able to say if $2 is less than or equal to 1 then compress $9. Any help would be appreciated.