A helper function for setting up an argparse parser.