Skip to content

Commit 91725a6

Browse files
committed
chore: update install plugins.sh
1 parent 47d318a commit 91725a6

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

plugins/install-plugins.sh

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,21 @@ install_plugin() {
1111
plugin=$1
1212

1313
if [ -d "$plugin/.git" ]; then
14-
echo "Repository for $plugin exists. Pulling latest changes..."
15-
cd "$plugin"
16-
git pull
14+
echo "[$plugin] Pulling..."
15+
cd "$plugin"
16+
git pull
1717
else
18-
echo "Repository for $plugin does not exist. Cloning..."
19-
git clone git@github.com:devforth/$plugin.git "$plugin"
20-
cd "$plugin"
18+
echo "[$plugin] Cloning..."
19+
git clone git@github.com:devforth/$plugin.git "$plugin"
20+
cd "$plugin"
2121
fi
2222

2323
cd ..
2424
}
2525

2626
do_npm_ci() {
2727
plugin=$1
28+
echo "[$plugin] npm ci"
2829
cd "$plugin"
2930
npm ci
3031
cd ..
@@ -33,8 +34,8 @@ do_npm_ci() {
3334
export -f install_plugin
3435
export -f do_npm_ci
3536

36-
echo $PLUGINS | tr ' ' '\n' | xargs -P 0 -I {} bash -c 'install_plugin "$@"' _ {}
37+
echo $PLUGINS | tr ' ' '\n' \
38+
| xargs -P 0 -I {} bash -c 'install_plugin "$@"' _ {}
3739

38-
echo $PLUGINS | tr ' ' '\n' | while read plugin; do
39-
do_npm_ci "$plugin"
40-
done
40+
echo $PLUGINS | tr ' ' '\n' \
41+
| xargs -P 0 -I {} bash -c 'do_npm_ci "$@"' _ {}

0 commit comments

Comments
 (0)