Note that there are some explanatory texts on larger screens.

plurals
  1. POPython command line program: generate man page from existing documentation and include in the distribution
    primarykey
    data
    text
    <p>Following an (hopefully) common practice, I have a Python package that includes several modules and an executable script in a separate <code>scripts</code> directory, as can be seen <a href="http://bitbucket.org/steko/totalopenstation/src" rel="noreferrer">here</a>.</p> <p>The documentation for the script, apart from the auto-generated help given by optparse, is together with the package documentation in a Sphinx subdirectory. I am trying to:</p> <ol> <li>generate the man page for the script from the existing documentation</li> <li>include the man page in the distribution</li> </ol> <p>I can easily do #1 with Sphinx, the <code>man_pages</code> setting and <code>sphinx-build -b man</code>. So I can call <code>python setup.py build_sphinx -b man</code> and have the man page generated in the <code>build/sphinx/man</code> directory.</p> <p>Now I would like to be able to have the generated man page included in the distribution tarball, so GNU/Linux packagers can find it and install it to the proper location. Various options like <code>package_data</code> do not seem to work here because the man page is not there until it is generated by Sphinx. This could also apply to i18n files (<code>.mo</code> vs <code>.po</code> files).</p> <p>Including files that are not part of the source in <code>MANIFEST.in</code> doesn't seem right. The possibility of commiting the generated files to the source repository looks like an awful thing to do and I would like to avoid it.</p> <blockquote> <p>There should be one-- and preferably only one --obvious way to do it.</p> </blockquote>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload