projects
/
monkeysphere.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f02e0df
)
catch pipe failures more cleanly during key import
author
Daniel Kahn Gillmor
<dkg@fifthhorseman.net>
Thu, 19 Feb 2009 05:35:50 +0000
(
00:35
-0500)
committer
Daniel Kahn Gillmor
<dkg@fifthhorseman.net>
Thu, 19 Feb 2009 05:35:50 +0000
(
00:35
-0500)
src/share/ma/add_certifier
patch
|
blob
|
history
diff --git
a/src/share/ma/add_certifier
b/src/share/ma/add_certifier
index 2f297598c28fa4fe437238f38f9d6f27a1c03024..7c1441c0429867a83d9c95933a04d8ba8116bc5f 100644
(file)
--- a/
src/share/ma/add_certifier
+++ b/
src/share/ma/add_certifier
@@
-84,7
+84,8
@@
if [ -f "$keyID" ] ; then
# + failure 'could not read key from '\''/root/dkg.gpg'\'''
# + echo 'could not read key from '\''/root/dkg.gpg'\'''
- keyID=$(echo "$importinfo" | grep '^gpg: key ' | cut -f2 -d: | cut -f3 -d\ )
+ keyID=$(echo "$importinfo" | grep '^gpg: key ' | cut -f2 -d: | cut -f3 -d\ ) || \
+ failure "There were no gpg keys in the file."
if [ -z "$keyID" ] || [ $(echo "$keyID" | wc -l) -ne 1 ] ; then
failure "There was not exactly one gpg key in the file."
fi