mirror of
https://github.com/corda/corda.git
synced 2024-12-19 13:08:04 +00:00
8862920f9a
Make docsite is back in a shell file due to issues invokving outside of the virtualenv.
32 lines
825 B
Bash
Executable File
32 lines
825 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# The purpose of this file is to install the requirements for the docsite
|
|
# You can call it manually if running make manually, otherwise gradle will run it for you
|
|
|
|
set -xeo pipefail
|
|
|
|
# Install the virtualenv
|
|
if [ ! -d "virtualenv" ]
|
|
then
|
|
# Check if python2.7 is installed explicitly otherwise fall back to the default python
|
|
if type "python2.7" > /dev/null; then
|
|
virtualenv -p python2.7 virtualenv
|
|
else
|
|
virtualenv virtualenv
|
|
fi
|
|
fi
|
|
|
|
# Activate the virtualenv
|
|
if [ -d "virtualenv/bin" ]
|
|
then
|
|
# it's a Unix system
|
|
source virtualenv/bin/activate
|
|
else
|
|
source virtualenv/Scripts/activate
|
|
fi
|
|
|
|
# Install PIP requirements
|
|
if [ ! -d "virtualenv/lib/python2.7/site-packages/sphinx" ]
|
|
then
|
|
echo "Installing pip dependencies ... "
|
|
pip install -r requirements.txt
|
|
fi |