This seems like you want to use subparsers.
from argparse import ArgumentParser parser = ArgumentParser() subparsers = parser.add_subparsers() install = subparsers.add_parser('install') install.add_argument('-b') install.add_argument('-a') install.set_defaults(subparser='install') lst = subparsers.add_parser('list') lst.set_defaults(subparser='list') update = subparsers.add_parser('update') update.set_defaults(subparser='update') print parser.parse_args() As stated in the docs, this can beI have combined with set_defaults in interesting waysso that you can know which subparser was invoked.