Get rid of config.py.

Instead, use better command line options and localise previously global
variables.
Refactor and rename list_modules().