#! /usr/bin/gawk -f # Last edited on 1999-01-05 09:08:20 by stolfi # Recreate the fnum-to-pnum table from the INDEX index # Usage: get-fnum-to-pnum-table < INDEX > fnum-to-pnum.tbl BEGIN { FS=":"; } (NF>0) { if (NF != 8) { printf "line %d, bad format\n" > "/dev/stderr"; exit 1; } if ($2 !~ /[.]/) { if ($7 != "-") { pg = $7; } printf "%s %s\n", $2, pg; } }