ant-design/scripts/ci-mock-project-build.sh

26 lines
606 B
Bash
Raw Normal View History

2023-03-15 10:51:14 +08:00
# Create a umi project
# clean up
rm -rf ~tmpProj/
2023-11-17 10:26:03 +08:00
# clean up `packageManager` since this will block yarn install
echo "Cleaning up package.json..."
sed -i '/packageManager/d' 'package.json' # linux no need for `''`
sed -i '' '/packageManager/d' 'package.json' # mac need `''`
2023-03-15 10:51:14 +08:00
# clone project
2023-11-17 10:26:03 +08:00
echo "Cloning project..."
git clone https://github.com/ant-design/ant-design-examples.git ~tmpProj --depth=1
2023-03-15 10:51:14 +08:00
# change directory
2023-11-17 10:26:03 +08:00
echo "Changing directory..."
cd ~tmpProj/examples/with-nextjs-inline-style
# install dependencies
2023-11-17 10:26:03 +08:00
echo "Installing dependencies..."
yarn
2023-03-15 10:51:14 +08:00
# build
2023-11-17 10:26:03 +08:00
echo "Building..."
yarn run build