From d272622bb01e7b30fb9799a2ccd6fadeabad821d Mon Sep 17 00:00:00 2001 From: Bert Peters Date: Tue, 19 Mar 2019 12:50:28 +0100 Subject: [PATCH 1/2] Exit when retrieving updates fails. --- plugins/other/pacman_pending_updates | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/other/pacman_pending_updates b/plugins/other/pacman_pending_updates index c5e66b93..7a327995 100755 --- a/plugins/other/pacman_pending_updates +++ b/plugins/other/pacman_pending_updates @@ -25,7 +25,7 @@ This plugin will draw one line: the number of updates pending. =head1 VERSION - 1.1.0 + 1.1.1 =head1 AUTHOR @@ -54,7 +54,7 @@ EOM ;; *) - updates="$(checkupdates)" + updates="$(checkupdates)" || exit if [ -n "$updates" ]; then echo "updates.value $(echo "$updates" | wc -l)" echo "updates.extinfo $(echo "$updates" | paste -s -d,)" From 6cb5c9e104d9a1a95adba7ce6e97651232c3595e Mon Sep 17 00:00:00 2001 From: Bert Peters Date: Mon, 10 Jun 2019 16:55:12 +0200 Subject: [PATCH 2/2] Properly report unknowns --- plugins/other/pacman_pending_updates | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/other/pacman_pending_updates b/plugins/other/pacman_pending_updates index 7a327995..00c2ecdb 100755 --- a/plugins/other/pacman_pending_updates +++ b/plugins/other/pacman_pending_updates @@ -54,7 +54,7 @@ EOM ;; *) - updates="$(checkupdates)" || exit + updates="$(checkupdates)" || echo "updates.value U" && exit if [ -n "$updates" ]; then echo "updates.value $(echo "$updates" | wc -l)" echo "updates.extinfo $(echo "$updates" | paste -s -d,)"