Enhanced Flag Handling

Rename flags to match JSON config names, split flags into two sets
(global and database), and print config on launch.

This could be better. Specifically the flag module makes a lot of
assumptions about your use case. It does not expect that you'd have
two flag sets operating on the same argument list. So it prints
some spurious errors which can be safely ignored. Probably the right
approach is to stop using the built-in flags module and instead
use some kind of fancier option parser.