BEGIN { FS=" "; } NR == 1 { nf=split(FILENAME,f,".") print ""; print "" f[1] ""; print ""; print "

Vim Documentation: " f[1] "

"; print ""; print "
"; print "
";
}

{
	#
	# protect special chars
	#
	gsub(/&/,"\\&");
	gsub(/>/,"\\>");
	gsub(/ 0)
	{
		print "==============" > "errors.log"
		print "Duplicate Tag " tag[1] > "errors.log"
		print "==============" > "errors.log"
	}
	counttag[tag[1]]++
	tagkey[t]=tag[1];tagref[t]=tag[2];tagnum[t]=NR;
	print $1 "	" $2 "	line " NR >"tags.ref"
	n=split($2,w,".");
	printf ("|%s|	%s\n",w[1],$1,$1,$2);
}

END     {
	topback();
	print "
\n\n\n\n"; } # # as main we keep index.txt (by default) # other candidate, help.txt # function topback () { printf("top - "); printf("back to help\n"); }