awk question




Guys,

Having found $9 , how do I /bin/rm it (using system()--yes??)
in an awk one-liner?

I'm trying to remove from packages from long ago and find and
print them with

ls -lt | awk '{if ($8 == 2006) print $9}';

but what I want to remove the file pointed at by $9. I've tried
FILE=ARGV[9]; and using FILE within my system() call, but no-joy.
What's the magic here?

thanks in advance,

gary



--
Gary Kline kline@xxxxxxxxxxx www.thought.org Public Service Unix

_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: awk question
    ... On Mon, Mar 05, 2007, Gary Kline wrote: ... in an awk one-liner? ... I'm trying to remove from packages from long ago and find and ... bill@xxxxxxxxxxxxx Bill Campbell; Celestial Software LLC ...
    (freebsd-questions)
  • Re: awk question
    ... Gary Kline wrote: ... in an awk one-liner? ... I'm trying to remove from packages from long ago and find and ... using pkg_delete would be safer: ...
    (freebsd-questions)
  • Re: awk question
    ... in an awk one-liner? ... You could pipe the output of awk through "| xargs rm -rf"...but be ... Gary Kline kline@xxxxxxxxxxx www.thought.org Public Service Unix ...
    (freebsd-questions)
  • whats the best way to re-install ports as packages?
    ... 6.1, packages are now available. ... portupgradingg stuff. ... kde-lite and gnome2-lite among them. ... Gary Kline kline@xxxxxxxxxxx www.thought.org Public service Unix ...
    (freebsd-questions)