doc/conf: disable "undefined name" warning from flake8

"tags" is exposed by sphinx, so we will have access to this variable
when sphinx imports this file. this silences the warning from flake8:

undefined name 'tags' [F821]

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2020-11-20 11:04:43 +08:00
parent f3f0b3027e
commit 664547a665

View File

@ -12,7 +12,7 @@ templates_path = ['_templates']
source_suffix = '.rst'
master_doc = 'index'
exclude_patterns = ['**/.#*', '**/*~', 'start/quick-common.rst', '**/*.inc.rst']
if tags.has('man'):
if tags.has('man'): # noqa: F821
master_doc = 'man_index'
exclude_patterns += ['index.rst', 'architecture.rst', 'glossary.rst', 'release*.rst',
'api/*',