report¶
Creates a collection report in file specified by target
.
Please be sure to specify this report as one of the latest collections, otherwise other collections have not been executed before this report gets generated.
collections = {
'my_collection_report: {
'driver': 'report',
'target': 'reports/collections.rst'
}
}
}
Hint
The executed
option in the report for the current report-collection is always False
, as this
options gets changed after the report was successfully generated.
The following template is used to build the report:
Collection Report
=================
{% for collection in collections %}
{{ collection.name }}
{{ "-" * collection.name|length }}
**Active**: {{ collection.active }}
**Executed**: {{ collection.executed }}
**Source**: {{ collection.config['source'] }}
**Target**: {{ collection.config['target'] }}
.. code-block:: text
{{ collection.config }}
{% endfor %}
driver_test¶
Active: False
Executed: False
Source: ../tests/dummy/
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/driver_test
{'driver': 'my_driver', 'source': '../tests/dummy/', 'active': False, 'name': 'driver_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/driver_test', 'safe': True}
copy_folder_test¶
Active: False
Executed: False
Source: ../tests/dummy/
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/copy_folder_test
{'driver': 'copy_folder', 'source': '../tests/dummy/', 'ignore': ['*.dat'], 'active': False, 'name': 'copy_folder_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/copy_folder_test', 'safe': True}
copy_file_test¶
Active: False
Executed: False
Source: ../tests/dummy/dummy.rst
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_new.rst
{'driver': 'copy_file', 'source': '../tests/dummy/dummy.rst', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_new.rst', 'active': False, 'name': 'copy_file_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
string_test¶
Active: False
Executed: False
Source: Take this!!!
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_string.rst
{'driver': 'string', 'source': 'Take **this**!!!', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_string.rst', 'active': False, 'name': 'string_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
function_test¶
Active: False
Executed: False
Source: <function my_func at 0x7fc2461a8400>
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_function.rst
{'driver': 'function', 'source': <function my_func at 0x7fc2461a8400>, 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/dummy_function.rst', 'active': False, 'name': 'function_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
report¶
Active: True
Executed: False
Source:
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/doc_collection_report.rst
{'driver': 'report', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/doc_collection_report.rst', 'active': True, 'name': 'report', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
symlink_test¶
Active: False
Executed: False
Source: ../tests/dummy/
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/symlink_test
{'driver': 'symlink', 'source': '../tests/dummy/', 'active': False, 'name': 'symlink_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/symlink_test', 'safe': True}
jinja_test¶
Active: False
Executed: False
Source: examples/jinja_template.rst.temp
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/my_jinja_test_{{name}}.rst
{'driver': 'jinja', 'source': 'examples/jinja_template.rst.temp', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/my_jinja_test_{{name}}.rst', 'data': {'name': 'me', 'city': 'munich'}, 'active': False, 'name': 'jinja_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
jinja_test_multiple¶
Active: False
Executed: False
Source: examples/jinja_template.rst.temp
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/my_jinja_test_{{name|lower}}.rst
{'driver': 'jinja', 'source': 'examples/jinja_template.rst.temp', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/my_jinja_test_{{name|lower}}.rst', 'multiple_files': True, 'data': [{'name': 'Marco', 'city': 'Munich'}, {'name': 'Daniel', 'city': 'Soest'}], 'active': False, 'name': 'jinja_test_multiple', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'safe': True}
git_test¶
Active: False
Executed: False
Source: https://github.com/useblocks/sphinx_dummy.git
Target: /home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/git_test
{'driver': 'git', 'source': 'https://github.com/useblocks/sphinx_dummy.git', 'active': False, 'name': 'git_test', 'confdir': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs', 'target': '/home/docs/checkouts/readthedocs.org/user_builds/sphinx-collections/checkouts/latest/docs/_collections/git_test', 'safe': True}
Clean up behavior¶
During clean up the target folders, which contains the report, gets deleted.