acbs_copy_git

# FIXME: Node.js 16 is unsupported.
abinfo "Installing Node.js 16 ..."
# FIXME: .nvmrc points to Node.js 14
rm -v "$SRCDIR"/.nvmrc
fnm install 16
# NOTE: fnm will wrap cd with it owns.
# if cd was called, "fnm use --silent-if-unchanged" will be executed, 
# which will lead to an interactive prompt for installing the specified Node version 
# (and waiting for input forever). Hence do install in advance.
eval "$(fnm env --use-on-cd --shell bash)"
fnm default 16
fnm use 16

abinfo "Prevent Corepack from showing the URL ..."
export COREPACK_ENABLE_DOWNLOAD_PROMPT=0

abinfo "Install yarn for Node.js 16"
npm install --global yarn

yarn install --frozen-lockfile

abinfo "Setting up the build environment ..."
cp -av "$SRCDIR"/.env.example "$SRCDIR"/.env
