Blame SOURCES/0071-console-notifications-skip-non-interactive-shells.patch

44797e
From bbd1e3c8765a8e28d4ade94eff60640c140b436a Mon Sep 17 00:00:00 2001
44797e
From: Jakub Filak <jfilak@redhat.com>
44797e
Date: Sat, 11 Oct 2014 00:05:07 +0200
44797e
Subject: [ABRT PATCH 71/71] console-notifications: skip non-interactive shells
44797e
44797e
Related to rhbz#1141485
44797e
Related to rhbz#1139001
44797e
44797e
Signed-off-by: Jakub Filak <jfilak@redhat.com>
44797e
---
44797e
 src/cli/abrt-console-notification.sh | 3 +++
44797e
 1 file changed, 3 insertions(+)
44797e
44797e
diff --git a/src/cli/abrt-console-notification.sh b/src/cli/abrt-console-notification.sh
44797e
index 38de7bb..976dfc3 100755
44797e
--- a/src/cli/abrt-console-notification.sh
44797e
+++ b/src/cli/abrt-console-notification.sh
44797e
@@ -3,6 +3,9 @@
44797e
 # terminal.
44797e
 tty -s || return 0
44797e
 
44797e
+# Skip all for noninteractive shells for the same reason as above.
44797e
+[ -z "$PS1" ] && return 0
44797e
+
44797e
 # If $HOME is not set, a non human user is logging in to shell but this script
44797e
 # should provide information to human users, therefore returning immediately
44797e
 # without showing the notification.
44797e
-- 
44797e
1.8.3.1
44797e