coze-studio/common/_templates/rspack-web/scm_build.sh

25 lines
386 B
Bash

#!/usr/bin/env bash
set -ex
# Switch cwd to the project folder
cd $(dirname "$0")
# Import the utilities functions
source ../../scripts/scm_base.sh
# Clean up the build directory
rm -rf output
rm -rf "${ROOT_DIR}"/output
# Prepare
prepare_environment
# Install the dependencies
install_project_deps
build_project
mkdir -p ${ROOT_DIR}/output
cp -r ./output/* ${ROOT_DIR}/output/