File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 3
3
json_key=$1
4
4
json_file=${2:- package.json}
5
5
6
- plugins=$( cat $json_file | npx --yes jqn " $1 " | tr -d " '[]:,\" \n " )
6
+ plugins=$( cat $json_file | npx --yes jqn " $1 " | tr -d " '[]:,\" " )
7
7
8
8
if [ -z " $plugins " ]; then
9
9
zz_log w " No plugins found at key {B $json_key } in {U $json_file }"
10
10
elif ! npm list $plugins 2> /dev/null 1>&2 ; then
11
+
12
+ config=$( dirname $0 ) /.ci-plugins
13
+
14
+ # Save the plugins to a config file
15
+ zz_log i " Adding plugins {B $plugins } to list of CI dependencies ..."
16
+ echo " $plugins " | sed ' s/^ *//;s/ *$//' | grep -v --file=$config >> $config
17
+
18
+ # Reload the plugins list
19
+ plugins=$( cat $config | tr ' \n' ' ' )
20
+
21
+ # Install the plugins
11
22
zz_log i " Installing plugins {B $plugins } ..."
12
23
npm install --no-save $plugins 2> /dev/null 1>&2
13
24
zz_log s " Plugins {B $plugins } installed successfully!"
Original file line number Diff line number Diff line change 2
2
"id" : " githooks" ,
3
3
"name" : " Git Hooks" ,
4
4
"description" : " A feature to add useful Git hooks to your project" ,
5
- "version" : " 5.10.1 " ,
5
+ "version" : " 5.10.2 " ,
6
6
"dependsOn" : {
7
7
"ghcr.io/devcontainers/features/node:1" : " lts" ,
8
8
"ghcr.io/tomgrv/devcontainer-features/common-utils:3" : {},
You can’t perform that action at this time.
0 commit comments