aboutsummaryrefslogtreecommitdiff
path: root/duply/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'duply/scripts')
-rw-r--r--duply/scripts/duplicity/duply_common.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/duply/scripts/duplicity/duply_common.sh b/duply/scripts/duplicity/duply_common.sh
index a1a8866..a55bfd6 100644
--- a/duply/scripts/duplicity/duply_common.sh
+++ b/duply/scripts/duplicity/duply_common.sh
@@ -17,7 +17,12 @@ function gpg_sec_avail {
read() {
if command -v zenity &> /dev/null
then
- eval $2=$(zenity --password)
+ RESULT=$(zenity --password 2>/dev/null)
+ if [ $? -ne 0 ]; then
+ command read $*
+ else
+ eval $2=${RESULT}
+ fi
else
command read $*
fi