aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormerakor <cem@ckyln.com>2020-08-21 20:58:14 +0000
committermerakor <cem@ckyln.com>2020-08-21 20:58:14 +0000
commit1099303cfe176b8374ff732579b2175b96209110 (patch)
tree48359a505df1421863732df3a08c9a4f79c2d675
parent50afd78b9ba890ed182373eec38c374515f18618 (diff)
downloadcpt-1099303cfe176b8374ff732579b2175b96209110.tar.gz
run_hook: only show package if $2 is available.
FossilOrigin-Name: 4da4abf26a685da9cbfc2eaa194f56ac19bc0fc8ca8aa9f8eca05447cfeda12b
-rw-r--r--src/cpt-lib2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cpt-lib b/src/cpt-lib
index c841da1..c6736b1 100644
--- a/src/cpt-lib
+++ b/src/cpt-lib
@@ -118,7 +118,7 @@ run_hook() {
[ -f "$CPT_HOOK" ] || return 0
- log "$2" "Running $1 hook"
+ [ "$2" ] && log "$2" "Running $1 hook"
TYPE=${1:-null} PKG=${2:-null} DEST=${3:-null} . "$CPT_HOOK"
}