#!/usr/bin/awk -f # Downloadable example 5 for GNU Awk Part 15 BEGIN { cmd = "wget -q http://hackerpublicradio.org/stats.php -O -" while ((cmd | getline) > 0) { if ($0 ~ /^Shows in Queue:/) printf "Queued shows on HPR: %d\n", $4 } close(cmd) }