All Projects → ociu → sphinx-traceability-extension

ociu / sphinx-traceability-extension

Licence: GPL-3.0 License
Traceability extension for Sphinx documentation generator

Programming Languages

python
139335 projects - #7 most used programming language
Batchfile
5799 projects
Makefile
30231 projects

Projects that are alternatives of or similar to sphinx-traceability-extension

foodprint
Algorand dApp for blockchain-enabled food transparency and traceability in local food supply chains. For use by smallholder farmers, food co-operatives and consumers.
Stars: ✭ 43 (+79.17%)
Mutual labels:  traceability
osrmt
Open Source Requirements Management Tool
Stars: ✭ 110 (+358.33%)
Mutual labels:  requirements-tracing
vue-ueditor-wrap
🚴Vue + 🚄UEditor + v-model双向绑定🚀
Stars: ✭ 1,461 (+5987.5%)
Mutual labels:  v-model
sphinxcontrib-programoutput
Sphinx extension for capturing program output
Stars: ✭ 29 (+20.83%)
Mutual labels:  sphinx-extension
epcis
Oliot EPCIS (Oliot EPC Information Service)
Stars: ✭ 32 (+33.33%)
Mutual labels:  traceability
readthedocs-sphinx-search
Enable search-as-you-type feature for docs hosted by RTD.
Stars: ✭ 24 (+0%)
Mutual labels:  sphinx-extension
sphinxcontrib-hdl-diagrams
Sphinx Extension which generates various types of diagrams from Verilog code.
Stars: ✭ 37 (+54.17%)
Mutual labels:  sphinx-extension
sphinxext-opengraph
Sphinx extension to generate unique OpenGraph metadata
Stars: ✭ 29 (+20.83%)
Mutual labels:  sphinx-extension
babel-plugin-react-directives
A babel plugin that provides some directives for react(JSX), similar to directives of vue.
Stars: ✭ 80 (+233.33%)
Mutual labels:  v-model
matlabdomain
A Sphinx extension for documenting Matlab code
Stars: ✭ 34 (+41.67%)
Mutual labels:  sphinx-extension
plantuml
No description or website provided.
Stars: ✭ 87 (+262.5%)
Mutual labels:  sphinx-extension
sphinxcontrib-jupyter
A Sphinx Extension for Generating Jupyter Notebooks
Stars: ✭ 72 (+200%)
Mutual labels:  sphinx-extension
emojicodes
An extension to use emoji codes in your Sphinx documentation! 😍
Stars: ✭ 39 (+62.5%)
Mutual labels:  sphinx-extension
Saway4ru
В этом релизе Вы найдете дополнительные материалы к книге "Путь аналитика. Практическое руководство ИТ-специалиста" (https://www.piter.com/product_by_id/40878036) Саму книгу можно заказать по адресу https://goo.gl/Av7Zmg
Stars: ✭ 22 (-8.33%)
Mutual labels:  requirements-engineering
sphinx-prompt
Sphinx directive to add unselectable prompt
Stars: ✭ 39 (+62.5%)
Mutual labels:  sphinx-extension
restbuilder
A Sphinx builder/writer to output reStructuredText (rst) files
Stars: ✭ 25 (+4.17%)
Mutual labels:  sphinx-extension
autodoc pydantic
Seamlessly integrate pydantic models in your Sphinx documentation.
Stars: ✭ 60 (+150%)
Mutual labels:  sphinx-extension
openapi
OpenAPI (fka Swagger) spec renderer for Sphinx.
Stars: ✭ 78 (+225%)
Mutual labels:  sphinx-extension
sphinx-wavedrom
A sphinx extension that allows including wavedrom diagrams by using its text-based representation
Stars: ✭ 26 (+8.33%)
Mutual labels:  sphinx-extension
sphinx rtd dark mode
Adds a toggleable dark mode to the Read the Docs theme for Sphinx.
Stars: ✭ 29 (+20.83%)
Mutual labels:  sphinx-extension

Sphinx traceability extension

Traceability extension for Sphinx documentation generator.

This extension adds directives and roles that serve to identify and relate portions of Sphinx documents and create lists and traceability matrices based on them.

It brings Sphinx the capability to work as a pretty decent document-oriented requirements management tool. Outside of the requirements domain, it can also be used for a wide range of documentation needs. Interesting features such as code-documentation traceability comes also out of the box.

Directives

.. item:: item_id [item_caption]
   :<<relationship>>:  other_item_id ...
   ...

   [item_content]

This directive identifies with item_id the portion of a document contained by the directive itself (item_content). If no item_content is defined, the directive just marks with item_id the position of the document where it is defined. An optional text can be defined with item_caption and it will be used in cross references instead of item_id.

The extension also checks for uniqueness of item identifiers through all files of a Sphinx project, in a similar way to standard Sphinx references.

The directive allows multiple :<<relationship>>: options that can set a list of item identifiers (space separated) the item traces to. The name of the option itself indicates the type of the relationship. For example:

.. item:: SW_REQ_001
   :addresses: SYS_REQ_001 SYS_REQ_002
   :tested_by: SW_TEST_005
   :allocated_to: SW_CSU_004
   ...

There is a predefined set of relationship names that can be used (the most typical in the systems / software engineering world). If no specific relationship type is to be set, just the generic :trace: relationship name can be used.

A configuration variable, traceability_relationships, can be used to extend and customize the set of available relationships. See Configuration for details.

.. item-list:: title
   :filter: regexp

This directive generates in place a list of items. A regular expression can be set with option :filter:, so that only items whose identifier matches the expression are written in the list.

.. item-matrix:: title
   :source: regexp
   :target: regexp
   :type: <<relationship>> ...

This directive generates in place a traceability matrix of item cross-references. :source: and :target: options can be used to filter matrix contents. Also content can be filtered based on traceability relationships.

Roles

Whenever an item needs to be referenced in documentation, it can be done with the :item: role. This item works the same way as any other Sphinx cross-reference role. By default, item identifier (or caption, if existing) shall be used in generated link text, but it can be overwritten with :role:`Text <target>` Sphinx syntax.

More on relationships

When setting a relationship from one item to another, this extension always considers the reverse relationship and sets it automatically from the latter to the former.

To do it, the internal relationship dictionary will always require a name for the reverse relationship. For bidirectional relationships, the same name shall be used. Examples:

  • depends_on: impacts_on
  • parent: child
  • sibling: sibling
  • trace: backtrace

This is a very effective way to make traceability matrices flexible and easy, as often matrices are requested in both directions. A traceability matrix from source A to target B according a relationship will have its automatic reverse matrix form B to A using its reverse relationship.

Configuration

traceability_relationships configuration variable follows the rules above. It is a dictionary with relationship/reverse pairs.

This is the set of predefined relationships (mostly related with standard UML relationships):

  • fulfills: fulfilled_by
  • depends_on: impacts_on
  • implements: implemented_by
  • realizes: realized_by
  • validates: validated_by
  • trace: backtrace (this is kept mainly for backwards compatibility)

Advanced configuration

By default, items are written as term/definition tuples, but this is fully customizable by defining traceability_item_template configuration variable. It uses Jinja2 templating language.

Note

using this template mechanism is not trivial. A good knowledge of Jinja2 is required.

Examples

There is an examples folder with some Sphinx projects you can run.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].