summaryrefslogtreecommitdiff
path: root/doc/conf.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2019-11-10 16:35:02 -0500
committerNed Batchelder <ned@nedbatchelder.com>2019-11-10 16:36:07 -0500
commit9c53e8b19ad12f1bb88bf11e8836d51da39cdbc2 (patch)
tree06e2df37a5cdcc09c4b559eff85297e54df66a9e /doc/conf.py
parent1dc17eaf6ed4bb2f2acb99fe7fe1f6857f645cc8 (diff)
downloadpython-coveragepy-git-9c53e8b19ad12f1bb88bf11e8836d51da39cdbc2.tar.gz
Automatically consider contributors' names as correctly spelled
Diffstat (limited to 'doc/conf.py')
-rw-r--r--doc/conf.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/doc/conf.py b/doc/conf.py
index fa36b020..1f7fc217 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -15,7 +15,9 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
+import atexit
import os
+import tempfile
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
@@ -187,7 +189,13 @@ htmlhelp_basename = 'coveragepydoc'
# -- Spelling ---
-spelling_word_list_filename = 'dict.txt'
+names_file = tempfile.NamedTemporaryFile(mode='w', prefix="coverage_names_", suffix=".txt")
+with open("../CONTRIBUTORS.txt") as contributors:
+ names_file.write("\n".join(contributors.read().split()))
+ names_file.flush()
+atexit.register(os.remove, names_file.name)
+
+spelling_word_list_filename = ['dict.txt', names_file.name]
spelling_show_suggestions = False
extlinks = {