Added support for new argument parsing code.

This new code still uses docopt but adds a layer that makes it less ugly and somewhat simpler.