summarylogtreecommitdiffstats
path: root/mkinitcpio-sign-install
diff options
context:
space:
mode:
Diffstat (limited to 'mkinitcpio-sign-install')
-rw-r--r--mkinitcpio-sign-install4
1 files changed, 2 insertions, 2 deletions
diff --git a/mkinitcpio-sign-install b/mkinitcpio-sign-install
index 4bacd2fe007..9d0942895aa 100644
--- a/mkinitcpio-sign-install
+++ b/mkinitcpio-sign-install
@@ -1,14 +1,14 @@
#!/bin/bash -e
pushd /usr/lib/initcpio/sign
-gpg-agent --daemon --max-cache-ttl 1
+gpg-connect-agent --homedir . reloadagent /bye
keys=(`gpg --homedir . --list-keys --with-colons | awk -F: '/^pub:/ { print $5 }' | tr '\n' ' '`)
if [[ $keys != "" ]]; then
echo "found $keys"
else
gpg --homedir . --gen-key
- [ $? -ne 0 ] && 1>&2 echo "you need to generate a GPG keypair to use for signing in /usr/lib/initcpio/sign" && exit 1
+ [ $? -ne 0 ] && 1>&2 echo "failed to generate a GPG keypair in /usr/lib/initcpio/sign" && exit 1
gpg --homedir . --export > ~/boot.key
fi