#!/bin/sh # Treats arguments as names of tcl source code files. # Creates a tag for each proc, then removes old definitions. awk ' $1 == "proc" && $2 ~ /^[^{}]*$/ { print $2 " " \ FILENAME " /^" $0 "$/" } ' ${1+"$@"} >> tags awk '{line[$1] = $0} END {for (l in line) { print line[l]}}' tags | sort > tags.$$ mv tags.$$ tags