> Does anyone have a working script that will count chunks of text separated
> by two newlines?
>
> I have a plain text file with names, addresses, phone numbers, etc. and
> I'm curious how many distinct entities are in the file. Each line ends with
> a newline, but they are separated by a blank line. I'm sure that such a tool
> can be cobbled together from shell tools or any scripting language and,
> rather than re-inventing the wheel, I'd like to use one already written.
i think that:
awk 'BEGIN{RS=""}END{print NR}'
will give you what you want.
_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug