Skip to content

Instantly share code, notes, and snippets.

@rjohnsondev
Last active March 20, 2017 06:22
Show Gist options
  • Save rjohnsondev/9f988ed6eca79a26660b3e8604100693 to your computer and use it in GitHub Desktop.
Save rjohnsondev/9f988ed6eca79a26660b3e8604100693 to your computer and use it in GitHub Desktop.
parser.add_argument(
'--mode',
default="test",
choices=["test", "launch", "populate", "worker"],
help='''What operation to run:
"test": Run in testing mode (single process, all local).
"launch": Launch and run everything.
"populate": Populate the central redis queue.
"worker": Run as a worker against the redis server.'''
)
# gives:
#
# optional arguments:
# -h, --help show this help message and exit
# --mode {test,launch,populate,worker}
# What operation to run: "test": Run in testing mode
# (single process, all local). "launch": Launch and run
# everything. "populate": Populate the central redis
# queue. "worker": Run as a worker against the redis
# server.
#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment