@@ -9,6 +9,7 @@ set -o pipefail # don't ignore exit codes when piping output
9
9
unset GIT_DIR # Avoid GIT_DIR leak from previous build steps
10
10
11
11
# ## Configure directories
12
+
12
13
BUILD_DIR=${1:- }
13
14
CACHE_DIR=${2:- }
14
15
ENV_DIR=${3:- }
@@ -34,8 +35,17 @@ install_sfdx_cli() {
34
35
chmod -R 755 " $BUILD_DIR /vendor/sfdx/cli"
35
36
}
36
37
38
+ install_jq () {
39
+ log " Downloading jq ..."
40
+ mkdir -p " $BUILD_DIR /vendor/sfdx/jq"
41
+ cd " $BUILD_DIR /vendor/sfdx/jq"
42
+ wget --quiet -O jq https://github.com/stedolan/jq/releases/download/jq-1.5/jq-linux64
43
+ chmod +x jq
44
+ }
45
+
37
46
setup_dirs () {
38
47
export PATH=" $BUILD_DIR /vendor/sfdx/cli/bin:$PATH "
48
+ export PATH=" $BUILD_DIR /vendor/sfdx/jq:$PATH "
39
49
}
40
50
41
51
header ' Welcome to salesforce-cli-buildpack!'
@@ -49,14 +59,17 @@ debug "CACHE_DIR: $CACHE_DIR"
49
59
debug " ENV_DIR: $ENV_DIR "
50
60
debug " BP_DIR: $BP_DIR "
51
61
52
- setup_dirs " $BUILD_DIR "
62
+ setup_dirs
53
63
log " Starting CLI installation ..."
54
- install_sfdx_cli " $BUILD_DIR "
64
+ install_sfdx_cli
65
+
66
+ log " Starting jq installation ..."
67
+ install_jq
55
68
56
- # Create vendor folder
69
+ # Create .profile.d folder
57
70
mkdir -p $BUILD_DIR /.profile.d
58
71
59
- # if no .profile, create one
72
+ # if no .profile.d/path.sh , create one
60
73
if [ ! -f $BUILD_DIR /.profile.d/path.sh ]; then
61
74
log " Creating path.sh ..."
62
75
echo " echo \" Updating PATH to include Salesforce CLI ...\"
0 commit comments