Message193737
This patch fixes the problem by joining the metavar terms with '|'. So the help for the test case (adapted from an existing tuple test) looks like:
usage: PROG [-h] W1 [W2 ...] [X1 [X2 ...]] Y1 Y2 Y3 [Z1]
positional arguments:
W1|W2 w
X1|X2 x
Y1|Y2|Y3 y
Z1 z
Alternatives include:
- use ',',' ',or '/' instead of '|'
- use just the 1st item of the tuple
- use the default (non-tuple) metavar in the help line
These all pass existing tests.
The last alternative would use:
#metavar = '|'.join(metavar)
if len(metavar)>1:
metavar = default
else:
metavar = metavar[0] |
|
Date |
User |
Action |
Args |
2013-07-26 20:20:50 | paul.j3 | set | recipients:
+ paul.j3, bethard, tshepang |
2013-07-26 20:20:50 | paul.j3 | set | messageid: <1374870050.31.0.0460672474295.issue14074@psf.upfronthosting.co.za> |
2013-07-26 20:20:50 | paul.j3 | link | issue14074 messages |
2013-07-26 20:20:50 | paul.j3 | create | |
|