2018-07-27 16:08:14 +03:00
|
|
|
#!/bin/bash
|
2018-09-25 20:45:08 +03:00
|
|
|
set -e
|
2018-09-25 20:01:10 +03:00
|
|
|
RIOT_BRANCH=develop
|
2018-07-18 19:04:31 +03:00
|
|
|
|
2019-04-05 17:26:05 +03:00
|
|
|
BASE_DIR=$(cd $(dirname $0) && pwd)
|
2019-04-03 17:20:26 +03:00
|
|
|
cd $BASE_DIR
|
2018-09-25 20:45:08 +03:00
|
|
|
# Install ComplexHttpServer (a drop in replacement for Python's SimpleHttpServer
|
|
|
|
# but with support for multiple threads) into a virtualenv.
|
|
|
|
(
|
2019-04-03 18:01:49 +03:00
|
|
|
virtualenv -p python3 env
|
2019-04-03 17:20:26 +03:00
|
|
|
source env/bin/activate
|
2018-09-25 20:45:08 +03:00
|
|
|
|
|
|
|
# Having been bitten by pip SSL fail too many times, I don't trust the existing pip
|
|
|
|
# to be able to --upgrade itself, so grab a new one fresh from source.
|
|
|
|
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
|
|
|
|
python get-pip.py
|
2019-04-03 17:20:26 +03:00
|
|
|
rm get-pip.py
|
2018-09-25 20:45:08 +03:00
|
|
|
|
|
|
|
pip install ComplexHttpServer
|
|
|
|
|
|
|
|
deactivate
|
|
|
|
)
|
|
|
|
|
2019-04-05 17:15:38 +03:00
|
|
|
if [ -d $BASE_DIR/riot-web ]; then
|
|
|
|
echo "riot is already installed"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2018-07-18 18:52:51 +03:00
|
|
|
curl -L https://github.com/vector-im/riot-web/archive/${RIOT_BRANCH}.zip --output riot.zip
|
2018-07-30 14:40:23 +03:00
|
|
|
unzip -q riot.zip
|
2018-07-18 18:52:51 +03:00
|
|
|
rm riot.zip
|
|
|
|
mv riot-web-${RIOT_BRANCH} riot-web
|
2018-07-27 15:10:19 +03:00
|
|
|
cd riot-web
|
2019-04-03 17:19:56 +03:00
|
|
|
yarn install
|
|
|
|
yarn run build
|