Skip to content

Commit 27b6254

Browse files
committed
documentation: describe how to setup a docs building environment
1 parent 76724f3 commit 27b6254

File tree

1 file changed

+27
-1
lines changed

1 file changed

+27
-1
lines changed

README.rst

+27-1
Original file line numberDiff line numberDiff line change
@@ -161,14 +161,40 @@ You can also run them in parallel:
161161
Building Sphinx docs
162162
~~~~~~~~~~~~~~~~~~~~
163163

164-
``cd`` into the ``doc`` directory and run:
164+
Setup a Python environment with ``sphinx`` and ``sagemaker``:
165+
166+
::
167+
168+
conda create -n sagemaker python=3
169+
conda activate sagemaker
170+
conda install sphinx
171+
pip install sagemaker --user
172+
173+
Install the Read The Docs theme:
174+
175+
::
176+
177+
pip install sphinx_rtd_theme
178+
179+
180+
Clone/fork the repo, ``cd`` into the ``sagemaker-python-sdk/doc`` directory and run:
165181

166182
::
167183

168184
make html
169185

170186
You can edit the templates for any of the pages in the docs by editing the .rst files in the ``doc`` directory and then running ``make html`` again.
171187

188+
Preview the site with a Python web server:
189+
190+
::
191+
192+
cd _build/html
193+
python -m http.server 8000
194+
195+
View the website by visiting http://localhost:8000
196+
197+
172198
MXNet SageMaker Estimators
173199
--------------------------
174200

0 commit comments

Comments
 (0)