From 1ba31d7ed03f0cab4f7b9104041eeb15dd1bf013 Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Wed, 11 Feb 2015 17:32:26 +0100 Subject: Suppress output when original file does not exist --- src/password-store.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/password-store.sh b/src/password-store.sh index 6313384..47f7ffa 100755 --- a/src/password-store.sh +++ b/src/password-store.sh @@ -421,7 +421,7 @@ cmd_edit() { fi ${EDITOR:-vi} "$tmp_file" [[ -f $tmp_file ]] || die "New password not saved." - $GPG -d -o - "${GPG_OPTS[@]}" "$passfile" | diff - "$tmp_file" &>/dev/null && die "Password unchanged." + $GPG -d -o - "${GPG_OPTS[@]}" "$passfile" 2>/dev/null | diff - "$tmp_file" &>/dev/null && die "Password unchanged." while ! $GPG -e "${GPG_RECIPIENT_ARGS[@]}" -o "$passfile" "${GPG_OPTS[@]}" "$tmp_file"; do yesno "GPG encryption failed. Would you like to try again?" done -- cgit v1.2.3