Browse Source

Merge "Make oslosphinx optional"

tags/3.0.1
Jenkins 2 years ago
parent
commit
df95641103
1 changed files with 8 additions and 2 deletions
  1. 8
    2
      doc/source/conf.py

+ 8
- 2
doc/source/conf.py View File

@@ -8,8 +8,14 @@ sys.path.insert(0, os.path.abspath('../..'))
8 8
 
9 9
 # Add any Sphinx extension module names here, as strings. They can be
10 10
 # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
11
-extensions = ['sphinx.ext.autodoc',
12
-              'oslosphinx']
11
+extensions = ['sphinx.ext.autodoc']
12
+# make oslosphinx optional to not increase the needed dependencies
13
+try:
14
+    import oslosphinx
15
+except ImportError:
16
+    pass
17
+else:
18
+    extensions.append('oslosphinx')
13 19
 
14 20
 # autodoc generation is a bit aggressive and a nuisance when doing heavy
15 21
 # text edit cycles.

Loading…
Cancel
Save