@@ -115,20 +115,22 @@ def setup_base(self):
115
115
def install_core_requirements (self ):
116
116
"""Install basic Read the Docs requirements into the virtualenv."""
117
117
requirements = [
118
- 'sphinx==1.5.3' ,
119
118
'Pygments==2.2.0' ,
120
119
'setuptools==28.8.0' ,
121
120
'docutils==0.13.1' ,
122
- 'mkdocs==0.15.0' ,
123
121
'mock==1.0.1' ,
124
122
'pillow==2.6.1' ,
125
- 'readthedocs-sphinx-ext<0.6' ,
126
- 'sphinx-rtd-theme<0.3' ,
127
123
'alabaster>=0.7,<0.8,!=0.7.5' ,
128
124
'commonmark==0.5.4' ,
129
125
'recommonmark==0.4.0' ,
130
126
]
131
127
128
+ if self .project .document_type == 'mkdocs' :
129
+ requirements .append ('mkdocs==0.15.0' )
130
+ else :
131
+ requirements .extend (['sphinx==1.5.3' , 'sphinx-rtd-theme<0.3' ,
132
+ 'readthedocs-sphinx-ext<0.6' ])
133
+
132
134
cmd = [
133
135
'python' ,
134
136
self .venv_bin (filename = 'pip' ),
@@ -211,12 +213,21 @@ def install_core_requirements(self):
211
213
"""Install basic Read the Docs requirements into the Conda env."""
212
214
# Use conda for requirements it packages
213
215
requirements = [
214
- 'sphinx' ,
215
216
'mock' ,
216
217
'pillow' ,
217
- 'sphinx_rtd_theme' ,
218
218
]
219
219
220
+ # Install pip-only things.
221
+ pip_requirements = [
222
+ 'recommonmark' ,
223
+ ]
224
+
225
+ if self .project .documentation_type == 'mkdocs' :
226
+ pip_requirements .append ('mkdocs' )
227
+ else :
228
+ pip_requirements .append ('readthedocs-sphinx-ext' )
229
+ requirements .extend (['sphinx' , 'sphinx-rtd-theme' ])
230
+
220
231
cmd = [
221
232
'conda' ,
222
233
'install' ,
@@ -229,13 +240,6 @@ def install_core_requirements(self):
229
240
* cmd
230
241
)
231
242
232
- # Install pip-only things.
233
- pip_requirements = [
234
- 'mkdocs' ,
235
- 'readthedocs-sphinx-ext' ,
236
- 'recommonmark' ,
237
- ]
238
-
239
243
pip_cmd = [
240
244
'python' ,
241
245
self .venv_bin (filename = 'pip' ),
0 commit comments