aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-gpgcrypt3
1 files changed, 2 insertions, 1 deletions
diff --git a/git-gpgcrypt b/git-gpgcrypt
index 730b45e..2b0c6fc 100755
--- a/git-gpgcrypt
+++ b/git-gpgcrypt
@@ -87,7 +87,8 @@ get_salt() {
}
encrypt_key() {
- echo "$1" | gpg -ea --group gr="$(sed -r -e 's/ +#[^#]*//' .recipients | tr '\n' ' ')" -r gr --output .gpgcrypt-key
+ echo "$1" | gpg -ea --group gr="$(sed -r -e 's/ +#[^#]*//' .recipients | tr '\n' ' ')" -r gr --output .gpgcrypt-key.tmp
+ mv .gpgcrypt-key.tmp .gpgcrypt-key
}
case "$1" in