Added command line parsing functions and better usage information.