Message261371
Oz Tiram wrote:
> I doubt if the correct place for formatting a man page should be in argparse.py itself. My solution is an extension of Andial's brecht solution
Thank you for that, Oz.
I see an easy seam to refactor this work into separate concerns.
The formatting of a man page from the parser for the command, can be coupled to the ‘argparse’ module since it is dependent only on an ArgumentParser plus some extra properties for populating the man page.
The building of one man page should not, IMO, be so tightly coupled to a Python distribution. There may be several different commands installed by one distribution. Each man page's fields should mostly come from the parser for the command, not from the distribution metadata. Instead, the build process should be told which parser to use for generating each of the man pages.
I propose to work on Oz's module and produce a man page formatter for exactly one ArgumentParser, as an enhancement for ‘argparse’. |
|
Date |
User |
Action |
Args |
2016-03-08 19:45:39 | bignose | set | recipients:
+ bignose, rhettinger, bethard, jwilk, eric.araujo, dmalcolm, Aaron.Meurer, andialbrecht, bochecha, tshepang, sigi, Daniel.Walsh, Ingo.Fischer, adregner, josh.r, Oz.Tiram |
2016-03-08 19:45:39 | bignose | set | messageid: <1457466339.75.0.539674435761.issue14102@psf.upfronthosting.co.za> |
2016-03-08 19:45:39 | bignose | link | issue14102 messages |
2016-03-08 19:45:39 | bignose | create | |
|