5
5
The basic operation is:
6
6
7
7
1. Add this extension to your ``conf.py`` extensions.
8
- 2. Add ``missing_references_freeze = True`` to your ``conf.py``
8
+ 2. Add ``missing_references_write_json = True`` to your ``conf.py``
9
9
3. Run sphinx-build. It will generate ``missing-references.json``
10
10
next to your ``conf.py``.
11
- 4. Remove ``missing_references_freeze = True`` from your
11
+ 4. Remove ``missing_references_write_json = True`` from your
12
12
``conf.py`` (or set it to ``False``)
13
13
5. Run sphinx-build again, and ``nitpick_ignore`` will
14
14
contain all of the previously failed references.
20
20
21
21
22
22
def record_missing_reference_handler (app , env , node , contnode ):
23
- if not app .config .missing_references_freeze :
23
+ if not app .config .missing_references_write_json :
24
24
# no-op when we are disabled.
25
25
return
26
26
@@ -38,7 +38,7 @@ def record_missing_reference_handler(app, env, node, contnode):
38
38
39
39
40
40
def save_missing_references_handler (app , exc ):
41
- if not app .config .missing_references_freeze :
41
+ if not app .config .missing_references_write_json :
42
42
# no-op when we are disabled.
43
43
return
44
44
@@ -48,7 +48,7 @@ def save_missing_references_handler(app, exc):
48
48
49
49
50
50
def prepare_missing_references_handler (app , config ):
51
- if config .missing_references_freeze :
51
+ if config .missing_references_write_json :
52
52
return
53
53
54
54
path = os .path .join (app .confdir , "missing-references.json" )
@@ -62,7 +62,7 @@ def prepare_missing_references_handler(app, config):
62
62
63
63
64
64
def setup (app ):
65
- app .add_config_value ("missing_references_freeze " , False , "env" )
65
+ app .add_config_value ("missing_references_write_json " , False , "env" )
66
66
67
67
app .connect ("config-inited" , prepare_missing_references_handler )
68
68
app .connect ("missing-reference" , record_missing_reference_handler )
0 commit comments