Add a group-by generator

This adds a group-by generator, along with documentation and a test
case.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Merge pull request #11 from algernon/f/group-by

Add a group-by generator