summaryrefslogtreecommitdiffstats
path: root/scripts/docs-build.sh
diff options
context:
space:
mode:
authorRyota MIBU <r-mibu@cq.jp.nec.com>2016-08-11 03:48:24 +0900
committerRyota MIBU <r-mibu@cq.jp.nec.com>2016-08-11 03:59:44 +0900
commit63ebeda6ddb4c0486442e3377d9951e2d3789bc9 (patch)
tree7126396312abc4526df86e53f5510817d9c935ea /scripts/docs-build.sh
parent59703f2ec84fa366ab1be9a0bfacd302c9c21155 (diff)
workaround for doc8 error in python2.6
Change-Id: I9b8967e564b522354f6fdcea51fe493c9682d36f Signed-off-by: Ryota MIBU <r-mibu@cq.jp.nec.com>
Diffstat (limited to 'scripts/docs-build.sh')
-rwxr-xr-xscripts/docs-build.sh8
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/docs-build.sh b/scripts/docs-build.sh
index b6bb5d5f7..e79e21c0b 100755
--- a/scripts/docs-build.sh
+++ b/scripts/docs-build.sh
@@ -190,7 +190,13 @@ if ! which virtualenv > /dev/null ; then
exit 1
fi
-virtualenv "$VENV_DIR"
+# workaround for doc8 error in python2.6
+if python -V | grep -q 'Python 2.6' && [ -e /usr/bin/python2.7 ] ; then
+ virtualenv "$VENV_DIR" --python=/usr/bin/python2.7
+else
+ virtualenv "$VENV_DIR"
+fi
+
source "$VENV_DIR/bin/activate"
pip install -r "$OPNFVDOCS_DIR/etc/requirements.txt"