Skip to content

Commit 50a95d0

Browse files
committed
Torchvision docs build script following pytorch/vision#285
1 parent 8145afc commit 50a95d0

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

jenkins/pytorch/build_nimbix.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,15 @@ if [ "$OS" == "LINUX" ]; then
250250
echo "Rebuilding and publishing sphinx docs"
251251
pip install --upgrade pip
252252
pip install --upgrade setuptools
253+
254+
pushd vision/docs
255+
# Make sure it is uninstalled!
256+
pip uninstall -y sphinx_rtd_theme || true
257+
pip uninstall -y sphinx_rtd_theme || true
258+
pip install -r requirements.txt || true
259+
make html
260+
popd
261+
253262
pushd docs
254263
# Make sure it is uninstalled!
255264
pip uninstall -y sphinx_rtd_theme || true
@@ -261,11 +270,20 @@ if [ "$OS" == "LINUX" ]; then
261270
echo $GITHUB_TOKEN >/tmp/token
262271
git clone https://pytorchbot:$GITHUB_TOKEN@github.com/pytorch/pytorch.github.io -b master tmp --quiet 2>&1 | grep -v $GITHUB_TOKEN || true
263272
cd tmp
273+
274+
# add pytorch docs
264275
git rm -rf docs/master || true
265276
mv ../build/html docs/master
266277
find docs/master -name "*.html" -print0 | xargs -0 sed -i -E 's/master[[:blank:]]\([[:digit:]]\.[[:digit:]]\.[[:digit:]]+\+[[:xdigit:]]+[[:blank:]]\)/<a href="http:\/\/pytorch.org\/docs\/versions.html">& \&#x25BC<\/a>/g'
267278
git add docs/master || true
268279
git status
280+
281+
# add torchvision docs
282+
git rm -rf docs/torchvision || true
283+
mv ../../vision/build/html docs/torchvision
284+
git add docs/torchvision || true
285+
git status
286+
269287
git config user.email "soumith+bot@pytorch.org"
270288
git config user.name "pytorchbot"
271289
git commit -m "auto-generating sphinx docs"

0 commit comments

Comments
 (0)