2023-02-17 10:45:42 +01:00
|
|
|
#!/usr/bin/env bash
|
2020-04-07 15:42:16 +02:00
|
|
|
|
2022-06-09 17:09:18 +02:00
|
|
|
set -e
|
|
|
|
|
2022-05-29 06:35:16 +02:00
|
|
|
cd packages/next
|
|
|
|
|
2023-01-03 10:05:50 +01:00
|
|
|
cp node_modules/webpack/lib/hmr/HotModuleReplacement.runtime.js src/bundles/webpack/packages/
|
|
|
|
cp node_modules/webpack/lib/hmr/JavascriptHotModuleReplacement.runtime.js src/bundles/webpack/packages/
|
|
|
|
cp node_modules/webpack/hot/lazy-compilation-node.js src/bundles/webpack/packages/
|
|
|
|
cp node_modules/webpack/hot/lazy-compilation-web.js src/bundles/webpack/packages/
|
2022-05-29 06:35:16 +02:00
|
|
|
|
|
|
|
pnpm run ncc-compiled
|
|
|
|
|
|
|
|
cd ../../
|
2020-04-07 15:42:16 +02:00
|
|
|
|
|
|
|
# Make sure to exit with 1 if there are changes after running ncc-compiled
|
|
|
|
# step to ensure we get any changes committed
|
|
|
|
|
2023-01-16 05:21:39 +01:00
|
|
|
if [[ ! -z $(git status -s) ]] && [[ -z $IS_PUBLISH ]];then
|
2020-04-07 15:42:16 +02:00
|
|
|
echo "Detected changes"
|
2021-09-21 19:17:16 +02:00
|
|
|
git diff -a --stat
|
2020-04-07 15:42:16 +02:00
|
|
|
exit 1
|
|
|
|
fi
|