Make dep install script work

pull/3945/head
David Baker 2017-05-17 18:14:28 +01:00
parent 60d33f50a7
commit 18afbc5bec
1 changed files with 23 additions and 4 deletions

View File

@ -8,9 +8,6 @@
curbranch=`git rev-parse --abbrev-ref HEAD`
mkdir -p node_modules
cd node_modules
function dodep() {
org=$1
repo=$2
@ -18,10 +15,32 @@ function dodep() {
git clone https://github.com/$org/$repo.git $repo
pushd $repo
git checkout $curbranch || git checkout develop
npm install
echo "$repo set to branch "`git rev-parse --abbrev-ref HEAD`
popd
}
dodep matrix-org matrix-js-sdk
dodep matrix-org matrix-react-sdk
mkdir -p node_modules
cd node_modules
ln -s ../matrix-js-sdk ./
pushd matrix-js-sdk
npm install
popd
ln -s ../matrix-react-sdk ./
pushd matrix-react-sdk
mkdir -p node_modules
cd node_modules
ln -s ../../matrix-js-sdk matrix-js-sdk
cd ..
npm install
popd
# Link the reskindex binary in place: if we used npm link,
# npm would do this for us, but we don't because we'd have
# to define the npm prefix somewhere so it could put the
# intermediate symlinks there. Instead, we do it ourselves.
mkdir -p .bin
ln -s ../matrix-react-sdk/scripts/reskindex.js .bin/reskindex