Fix pgp.sh complaining about grep

This commit is contained in:
David 2021-07-03 01:08:40 +01:00
parent b53add2798
commit dc7bae04c7
No known key found for this signature in database
GPG key ID: 913FE0F2477D7D6B

View file

@ -31,7 +31,7 @@ EOF
# - There isn't a fingerprint on /etc/mailinabox.conf # - There isn't a fingerprint on /etc/mailinabox.conf
# - The configured fingerprint doesn't actually exist # - The configured fingerprint doesn't actually exist
if [ "${PGPKEY-}" == "" -o "$(gpg --list-secret-keys 2> /dev/null | grep ${PGPKEY-})" = "" ]; then if [ -z "${PGPKEY:-}" -o "$(gpg --list-secret-keys 2> /dev/null | grep ${PGPKEY:-\r\n})" = "" ]; then
echo "No keypair found. Generating daemon's PGP keypair..." echo "No keypair found. Generating daemon's PGP keypair..."
gpg_keygen gpg_keygen
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then