mirror of
https://github.com/gradle/actions.git
synced 2025-11-26 17:09:10 +08:00
Improve local development script
- Avoid running `npm install` on every execution - Add a separate `install` task that runs `npm clean-install`
This commit is contained in:
17
build
17
build
@@ -4,12 +4,10 @@ cd sources
|
||||
|
||||
case "$1" in
|
||||
all)
|
||||
npm clean-install
|
||||
npm run all
|
||||
;;
|
||||
act)
|
||||
# Build and copy outputs to the dist directory
|
||||
npm install
|
||||
npm run build
|
||||
cd ..
|
||||
cp -r sources/dist .
|
||||
@@ -18,18 +16,21 @@ case "$1" in
|
||||
# Revert the changes to the dist directory
|
||||
git checkout -- dist
|
||||
;;
|
||||
init-scripts)
|
||||
cd test/init-scripts
|
||||
./gradlew check
|
||||
;;
|
||||
dist)
|
||||
npm install
|
||||
npm clean-install
|
||||
npm run build
|
||||
cd ..
|
||||
cp -r sources/dist .
|
||||
;;
|
||||
init-scripts)
|
||||
cd test/init-scripts
|
||||
./gradlew check
|
||||
;;
|
||||
install)
|
||||
npm clean-install
|
||||
npm run build
|
||||
;;
|
||||
*)
|
||||
npm install
|
||||
npm run build
|
||||
;;
|
||||
esac
|
||||
|
||||
Reference in New Issue
Block a user