summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorSerge Schneider <serge@raspberrypi.org>2018-03-02 20:08:24 +0000
committerSerge Schneider <serge@raspberrypi.org>2018-03-13 12:50:50 +0000
commitff2d5edee18efbb7ba2498e5bf8d308c186c4866 (patch)
tree380dd4fb8138fcbcf374839a880deb3191ca0725 /scripts
parent56da271499afe7ae8e35a8fd30f04135283b2fb0 (diff)
shellcheck
Diffstat (limited to 'scripts')
-rw-r--r--scripts/common6
-rw-r--r--scripts/dependencies_check4
2 files changed, 5 insertions, 5 deletions
diff --git a/scripts/common b/scripts/common
index f18fd89..efd867e 100644
--- a/scripts/common
+++ b/scripts/common
@@ -1,5 +1,5 @@
log (){
- date +"[%T] $@" | tee -a "${LOG_FILE}"
+ date +"[%T] $*" | tee -a "${LOG_FILE}"
}
export -f log
@@ -15,10 +15,10 @@ bootstrap(){
local BOOTSTRAP_CMD=debootstrap
fi
- capsh --drop=cap_setfcap -- -c "${BOOTSTRAP_CMD} --components=main,contrib,non-free \
+ capsh --drop=cap_setfcap -- "${BOOTSTRAP_CMD}" --components=main,contrib,non-free \
--arch armhf \
--keyring "${STAGE_DIR}/files/raspberrypi.gpg" \
- $1 $2 $3" || rmdir "$2/debootstrap"
+ "$1" "$2" "$3" || rmdir "$2/debootstrap"
}
export -f bootstrap
diff --git a/scripts/dependencies_check b/scripts/dependencies_check
index d649f0c..1b92a9c 100644
--- a/scripts/dependencies_check
+++ b/scripts/dependencies_check
@@ -10,11 +10,11 @@ dependencies_check()
for depfile in "$@"; do
if [[ -e "$depfile" ]]; then
- deps="$(sed -f "${SCRIPT_DIR}/remove-comments.sed" < ${BASE_DIR}/depends)"
+ deps="$(sed -f "${SCRIPT_DIR}/remove-comments.sed" < "${BASE_DIR}/depends")"
fi
for dep in $deps; do
- if ! hash ${dep%:*} 2>/dev/null; then
+ if ! hash "${dep%:*}" 2>/dev/null; then
missing="${missing:+$missing }${dep#*:}"
fi
done