2019-08-07 16:16:03 -04:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
if [[ "${NODE_ENV}" != "production" ]]; then
|
|
|
|
export WALLET_MNEMONIC='erupt point century seek certain escape solution flee elegant hard please pen'
|
|
|
|
export WALLET_PASSWORD='dev_password'
|
|
|
|
fi
|
|
|
|
|
2019-07-30 21:33:50 +03:00
|
|
|
echo "removing old full-build"
|
2019-08-05 14:26:46 -04:00
|
|
|
rm -rf full-build app.zip
|
|
|
|
echo "compiling contracts"
|
2019-08-07 17:53:04 +02:00
|
|
|
./node_modules/.bin/embark build
|
2019-07-30 21:33:50 +03:00
|
|
|
echo "creating new full-build"
|
|
|
|
mkdir full-build
|
|
|
|
cp -r back-end/* full-build/
|
2019-08-05 14:26:46 -04:00
|
|
|
echo "copying special files"
|
|
|
|
cp .npmrc full-build/
|
2019-07-30 21:33:50 +03:00
|
|
|
echo "building new frontend"
|
2019-08-07 13:59:56 -04:00
|
|
|
./node_modules/.bin/react-scripts build
|
2019-07-30 21:33:50 +03:00
|
|
|
echo "copying new frontend"
|
2019-08-07 13:59:56 -04:00
|
|
|
mkdir full-build/frontend
|
2019-07-30 21:33:50 +03:00
|
|
|
cp -r build/* full-build/frontend/
|
2019-08-05 14:26:46 -04:00
|
|
|
echo "archiving the build"
|
|
|
|
{
|
|
|
|
cd full-build;
|
|
|
|
zip -r ../app.zip ./
|
|
|
|
}
|
|
|
|
echo "Finished. Use the app.zip file."
|