From 94c9d11cb8b72d2723da27394ae5bb41713920be Mon Sep 17 00:00:00 2001 From: Thomas Eckert Date: Tue, 20 Feb 2018 10:20:54 +0100 Subject: [PATCH] fix messaging for __package_update_index The message was printed unconditionally, even if no `apt-get update` had been running. --- cdist/conf/type/__package_update_index/gencode-remote | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cdist/conf/type/__package_update_index/gencode-remote b/cdist/conf/type/__package_update_index/gencode-remote index d84e7953..37bfe7ab 100755 --- a/cdist/conf/type/__package_update_index/gencode-remote +++ b/cdist/conf/type/__package_update_index/gencode-remote @@ -54,11 +54,12 @@ case "$type" in ## check if we need to update: if [ $currage -ge $maxage ]; then echo "apt-get --quiet update" + echo "apt-cache updated (age was: $currage)" >> "$__messages_out" fi else echo "apt-get --quiet update" + echo "apt-cache updated (age was: $currage)" >> "$__messages_out" fi - echo "apt-cache updated (age was: $currage)" >> "$__messages_out" ;; pacman) echo "pacman --noprogressbar --sync --refresh" ;; *)