Allow overriding gpg command

This is particular useful on OS X when gnupg version 2 is installed with brew
which installs it as gpg2
This commit is contained in:
Denis Dzyubenko
2015-06-27 13:39:39 +02:00
parent 521d108df9
commit cef09190e9
3 changed files with 11 additions and 9 deletions

View File

@@ -24,7 +24,7 @@ while IFS= read <&99 -r unencrypted_file; do
encrypted_file=$(get_encrypted_filename "$unencrypted_file")
fail_if_not_on_cryptlist "$unencrypted_file"
if [[ -f "$unencrypted_file" ]]; then
out=$(diff -u <(gpg --yes -q --decrypt "$encrypted_file") "$unencrypted_file" || true)
out=$(diff -u <($GPG --yes -q --decrypt "$encrypted_file") "$unencrypted_file" || true)
if [ "$out" != "" ]; then
modified_files+=("$unencrypted_file")
modifications+=("$out")