This branch implements Templates as complete databases rather than as SQL scripts

When creating a database from a template, it uses the -T option to createdb

These new-style templates are initially called DatabaseTemplates, then renamed back
to Template after the old-style entities are removed.