gpgtar erroneously removes an existing output file if an error occurs.
Example:
# create an existing output file and a folder to archive: $ touch do-not-remove-me $ mkdir foo # run gpgtar; enter a passphrase when asked for it; deny overwriting the existing file; press Return when asked for new filename: $ gpgtar --encrypt --symmetric --output do-not-remove-me foo File 'do-not-remove-me' exists. Overwrite? (y/N) Enter new filename: gpg: symmetric encryption of '[stdin]' failed: File exists gpgtar: running /opt/gnupg/master/bin/gpg failed (exitcode=2): General error gpgtar: creating tarball 'do-not-remove-me' failed: General error # observe that your precious existing file is gone: $ ls do-not-remove-me ls: cannot access 'do-not-remove-me': No such file or directory