]> err.no Git - pwstore/commitdiff
Add .keyring to keyrings for verifying .users, if the file exists
authorPeter Palfrader <peter@palfrader.org>
Mon, 18 Jul 2011 14:23:06 +0000 (16:23 +0200)
committerPeter Palfrader <peter@palfrader.org>
Mon, 18 Jul 2011 14:23:10 +0000 (16:23 +0200)
pws

diff --git a/pws b/pws
index b81da23395cb88ed8de47448ed82dd630542520c..13c67832dccaa79cb2a434d90a23b22a1148015e 100755 (executable)
--- a/pws
+++ b/pws
@@ -232,7 +232,9 @@ class GroupConfig
       trusted.push line
     end
 
-    (outtxt, stderrtxt, statustxt, exitstatus) = GnuPG.gpgcall(content, %w{})
+    args = []
+    args.push "--keyring=./.keyring" if FileTest.exists?(".keyring")
+    (outtxt, stderrtxt, statustxt, exitstatus) = GnuPG.gpgcall(content, args)
     goodsig = false
     validsig = nil
     statustxt.split("\n").each do |line|