module sphinxext.sphinxext_helper

Short summary

module pyquickhelper.sphinxext.sphinxext_helper

Helpers for sphinx extensions.

source on GitHub

Functions

function

truncated documentation

try_add_config_value

Add a variables in the config file if it does not have it yet.

Documentation

Helpers for sphinx extensions.

source on GitHub

pyquickhelper.sphinxext.sphinxext_helper.try_add_config_value(app, name, default, rebuild, type_s=())[source][source]

Add a variables in the config file if it does not have it yet.

Parameters
  • app – Sphinx application

  • name – name of the variable

  • default – default value

  • rebuild – see below

  • type_s – expected types

Returns

True if added, False if already present.

Rebuilds can be (source: Sphinx.add_config_value):

  • ‘env’ if a change in the setting only takes effect when a document is parsed - this means that the whole environment must be rebuilt.

  • ‘html’ if a change in the setting needs a full rebuild of HTML documents.

  • ‘’ if a change in the setting will not need any special rebuild.

source on GitHub