Examples
The following page shows a few examples comparing Paperbush to argparse
.
from argparse import ArgumentParser
UNSET = object()
parser = ArgumentParser()
parser.add_argument("string", nargs="?", default=UNSET)
parser.add_argument(
"-d",
"--depth",
type=int,
choices=(3, 4, 8, 24),
default=4
)
parser.add_argument("-c", "--clean", action="store_true")
parser.add_argument("-t", "--test", action="store_true")