From a4b17a9af86ab88cfe48e616284b56c1bdf019bd Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Fri, 29 Dec 2017 13:02:15 +1300 Subject: Remove --batch option and wrapper for gpg(1) This was originally added to cut the decryption boilerplate, which no longer seems to be an issue; I think that --quiet may be correctly blocking it now. Even without this, it caused more problems than it solved when gpg(1) genuinely did need user interaction from me, for example for --update-trustdb. --- README.md | 1 - gnupg/gpg.conf.mi5 | 5 ----- sh/shrc.d/gpg.sh | 10 ---------- 3 files changed, 16 deletions(-) delete mode 100644 sh/shrc.d/gpg.sh diff --git a/README.md b/README.md index 3e602d65..e8b67350 100644 --- a/README.md +++ b/README.md @@ -205,7 +205,6 @@ in `sh/shrc.d` to be loaded by any POSIX interactive shell. Those include: * `ed()` tries to get verbose error messages, a prompt, and a Readline environment for `ed(1)`. * `gdb()` silences startup messages from `gdb(1)`. -* `gpg()` quietens `gpg(1)` down for most commands. * `grep()` tries to apply color and other options good for interactive use if available. * `hgrep()` allows searching `$HISTFILE`. diff --git a/gnupg/gpg.conf.mi5 b/gnupg/gpg.conf.mi5 index 1617a979..74363441 100644 --- a/gnupg/gpg.conf.mi5 +++ b/gnupg/gpg.conf.mi5 @@ -1,11 +1,6 @@ # Retrieve certs automatically if possible auto-key-locate cert pka -# Prevent boilerplate about needing key decryption, which is handled by the -# agent; the gpg function in my Bash scripts overrides this for certain -# commands where it interferes -batch - # Use SHA512 as the hash when making key signatures cert-digest-algo SHA512 diff --git a/sh/shrc.d/gpg.sh b/sh/shrc.d/gpg.sh deleted file mode 100644 index 62d123ea..00000000 --- a/sh/shrc.d/gpg.sh +++ /dev/null @@ -1,10 +0,0 @@ -# Wrapper around gpg(1) to stop ``--batch'' breaking things -gpg() { - # shellcheck disable=SC2048 - case $* in - *--ed*|*--gen-k*|*--sign-k*) - set -- --no-batch "$@" - ;; - esac - command gpg "$@" -} -- cgit v1.2.3