diff --git a/create-attributable-archive.sh b/create-attributable-archive.sh index dff4700..9857fba 100755 --- a/create-attributable-archive.sh +++ b/create-attributable-archive.sh @@ -29,12 +29,13 @@ reset() { find . -type f \( -path ".git" -o -path "keystore" -o -path "archives" \) -prune \( -name "*.sha512" -o -name "checksums*" -o -name "private_*" -o -name ".*" -o -name "*.sig" -o -name "*.7z" -o -name "anonymous_signer" \) -print -exec shred -uz {} \; checkcode $? - if [ -f private_* ]; then + if compgen -G "private_*"; then printf "nuking errant priv key files..." shred -uz private_* checkcode $? fi - if [ -f attribution_passphrase_* ]; then + + if compgen -G "attribution_passphrase_*" > /dev/null; then printf "nuking errant attribution passphrase files" shred -uz attribution_passphrase_* checkcode $?