global verbose and debug flags

Closes #848

This gets rid of the unwieldy and inconsistent passing of verbose and debug flags as function arguments. Now ```flags.verbose``` and ```flags.debug``` are set on command line parsing, and these can be accessed as needed from any source file.

@matthewrmshin - a large number of changes, but they're all trivial, so should be a quick review.

Test battery passes.