I am reading through argparse module. I got stuck as what to metavar and action means
>>> parser.add_argument('integers', metavar='N', type=int, nargs='+',
... help='an integer for the accumulator')
>>> parser.add_argument('--sum', dest='accumulate', action='store_const',
... const=sum, default=max,
... help='sum the integers (default: find the max)')
I might have missed but from what I read, I could not find definitions for metavar
and
action (action="store_const", etc)
. what do they actually mean?