actual/packages/desktop-client/bin/build-browser
2022-04-28 22:44:38 -04:00

17 lines
No EOL
493 B
Bash
Executable file

#!/bin/sh -ex
ROOT=`dirname $0`
cd "$ROOT/.."
VERSION=`cat "$ROOT/../../desktop-electron/package.json" | grep version | head -n1 | awk -F "\"" '{print $4}' | tr -d '\r\n'`
echo "Building version $VERSION for the browser..."
rm -fr build
export IS_GENERIC_BROWSER=1
export INLINE_RUNTIME_CHUNK=false
export REACT_APP_BACKEND_WORKER_HASH=`ls "$ROOT"/../public/kcab/kcab.worker.*.js | sed 's/.*kcab\.worker\.\(.*\)\.js/\1/'`
export REACT_APP_ACTUAL_VERSION="$VERSION"
node scripts/build.js