Skip to content

Commit ee2056d

Browse files
committed
Set env var in sphinx so we can check if a module is imported by sphinx
1 parent fcc5bce commit ee2056d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/conf.py

+2
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@
2626
import sphinx.environment
2727
from docutils.utils import get_source_line
2828

29+
# Enviroment variable used to code to detect if modules are imported by sphinx
30+
os.environ['DOCS_BUILDING'] = "True"
2931

3032
# Define a settings module
3133
os.environ['DEMOSYS_SETTINGS_MODULE'] = 'demosys.conf.default'

0 commit comments

Comments
 (0)