docs: kill api page

This commit is contained in:
Marian Beermann 2017-03-25 15:41:11 +01:00
parent e949dfcb54
commit 475d53d9ef
3 changed files with 3 additions and 143 deletions

View file

@ -1,99 +0,0 @@
API Documentation
=================
.. automodule:: borg.archiver
:members:
:undoc-members:
.. automodule:: borg.archive
:members:
:undoc-members:
.. automodule:: borg.repository
:members:
:undoc-members:
.. automodule:: borg.remote
:members:
:undoc-members:
.. automodule:: borg.cache
:members:
:undoc-members:
.. automodule:: borg.key
:members:
:undoc-members:
.. automodule:: borg.keymanager
:members:
:undoc-members:
.. automodule:: borg.nonces
:members:
:undoc-members:
.. automodule:: borg.item
:members:
:undoc-members:
.. automodule:: borg.constants
:members:
:undoc-members:
.. automodule:: borg.logger
:members:
:undoc-members:
.. automodule:: borg.helpers
:members:
:undoc-members:
.. automodule:: borg.locking
:members:
:undoc-members:
.. automodule:: borg.shellpattern
:members:
:undoc-members:
.. automodule:: borg.lrucache
:members:
:undoc-members:
.. automodule:: borg.fuse
:members:
:undoc-members:
.. automodule:: borg.selftest
:members:
:undoc-members:
.. automodule:: borg.xattr
:members:
:undoc-members:
.. automodule:: borg.platform.base
:members:
:undoc-members:
.. automodule:: borg.platform.linux
:members:
:undoc-members:
.. automodule:: borg.hashindex
:members:
:undoc-members:
.. automodule:: borg.compress
:members: get_compressor, Compressor, CompressorBase
:undoc-members:
.. automodule:: borg.chunker
:members:
:undoc-members:
.. automodule:: borg.crypto
:members:
:undoc-members:

View file

@ -217,12 +217,6 @@ However, we prefer to do this as part of our :ref:`releasing`
preparations, so it is generally not necessary to update these when
submitting patches that change something about the command line.
The code documentation (which is currently not part of the released
docs) also uses a generated file (``docs/api.rst``), that needs to be
updated when a module is added or removed::
python setup.py build_api
Building the docs with Sphinx
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@ -300,9 +294,9 @@ Checklist:
- update ``CHANGES.rst``, based on ``git log $PREVIOUS_RELEASE..``
- check version number of upcoming release in ``CHANGES.rst``
- verify that ``MANIFEST.in`` and ``setup.py`` are complete
- ``python setup.py build_api ; python setup.py build_usage ; python
setup.py build_man`` and commit (be sure to build with Python 3.4 as
Python 3.6 added `more guaranteed hashing algorithms
- ``python setup.py build_usage ; python setup.py build_man`` and
commit (be sure to build with Python 3.4 or 3.5 as Python 3.6 added `more
guaranteed hashing algorithms
<https://github.com/borgbackup/borg/issues/2123>`_)
- tag the release::

View file

@ -567,43 +567,8 @@ class build_man(Command):
write(option.ljust(padding), desc)
class build_api(Command):
description = "generate a basic api.rst file based on the modules available"
user_options = [
('output=', 'O', 'output directory'),
]
def initialize_options(self):
pass
def finalize_options(self):
pass
def run(self):
print("auto-generating API documentation")
with open("docs/api.rst", "w") as doc:
doc.write("""
.. IMPORTANT: this file is auto-generated by "setup.py build_api", do not edit!
API Documentation
=================
""")
for mod in sorted(glob('src/borg/*.py') + glob('src/borg/*.pyx')):
print("examining module %s" % mod)
mod = mod.replace('.pyx', '').replace('.py', '').replace('/', '.')
if "._" not in mod:
doc.write("""
.. automodule:: %s
:members:
:undoc-members:
""" % mod)
cmdclass = {
'build_ext': build_ext,
'build_api': build_api,
'build_usage': build_usage,
'build_man': build_man,
'sdist': Sdist