README 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. Manual page library for Python
  2. ##############################
  3. The standard Unix manual system is structured into documents, each
  4. called a “manual page” (or “man page”). This library helps you to
  5. generate these documents from Python code.
  6. Features
  7. ========
  8. * Python API for generating Unix manual page documents.
  9. * Integration with the `argparse.ArgumentParser` class for each
  10. command, to create a manual page document for the command.
  11. * Integration with the Setuptools build system, to generate manual
  12. page documents when building the distribution.
  13. Requirements
  14. ============
  15. * Python 3.3 or later.
  16. Motivation
  17. ==========
  18. While the Unix manual page system is a common standard, too many
  19. Python packages install commands, libraries, and file formats without
  20. any Unix manual pages.
  21. Legacy markup language
  22. ----------------------
  23. A manual page document is written in `troff`_, which is a text markup
  24. language. In the 21st century, almost nobody uses troff anymore
  25. *except* for writing Unix manual page documents, and there is a lack
  26. of experience in using the language well.
  27. So it's hard to find well-formatted manual pages, and many such pages
  28. do not conform to markup conventions for the system.
  29. The `manpage` library provides ways to generate Unix man pages,
  30. without any need to learn any troff.
  31. .. _troff: http://www.troff.org/
  32. Avoid duplicate documentation
  33. -----------------------------
  34. A good manual page document has a structure and contains significant
  35. information; it is not just a terse listing of command options.
  36. Neither is it a full end-user treatise or tutorial. Instead, it should
  37. be a concise reference work, in a standard format.
  38. Some parts of the manual page should be written specifically for that
  39. document. Others, though, can be automatically gathered from text
  40. written elsewhere.
  41. So it's hard to find well-written or complete manual pages, and many
  42. busy developers postpone writing them at all.
  43. The `manpage` library has various sensible defaults for a document's
  44. meta-data. It can also populate larger parts of the document from
  45. existing text in the Python code.
  46. Copying this work
  47. =================
  48. Copyright © 2016 Ben Finney <ben+python@benfinney.id.au>.
  49. This is free software: you may copy, modify, and/or distribute this work
  50. under the terms of the GNU General Public License as published by the
  51. Free Software Foundation; version 3 of that license or any later version.
  52. No warranty expressed or implied. See the file ‘LICENSE.GPL-3’ for details,
  53. or view it online at <URL:https://www.gnu.org/licenses/gpl-3.0.html>.
  54. ..
  55. Local variables:
  56. coding: utf-8
  57. mode: text
  58. mode: rst
  59. End:
  60. vim: fileencoding=utf-8 filetype=rst :