#!/bin/bash

git clone https://gitlab.iscpif.fr/gargantext/purescript-gargantext
cd purescript-gargantext

# as sudoer
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
#sudo apt update
sudo apt install yarn
# as user
yarn install && yarn install-ps && yarn build

# temporary bug (help welcome)
#cp src/index.html dist/index.html
#cd ..