[Pgp-tools-commit] r619 - trunk/keyart
Aaron Toponce
atoponce-guest at moszumanska.debian.org
Wed May 14 19:46:53 UTC 2014
Author: atoponce-guest
Date: 2014-05-14 19:46:53 +0000 (Wed, 14 May 2014)
New Revision: 619
Modified:
trunk/keyart/keyart
Log:
Add support for GnuPG v2 in case v1 is not installed.
Modified: trunk/keyart/keyart
===================================================================
--- trunk/keyart/keyart 2014-05-14 18:25:47 UTC (rev 618)
+++ trunk/keyart/keyart 2014-05-14 19:46:53 UTC (rev 619)
@@ -18,9 +18,14 @@
sys.exit(3)
try:
+ if os.access('/usr/bin/gpg',os.X_OK):
+ gpg_bin = '/usr/bin/gpg'
+ else:
+ gpg_bin = '/usr/bin/gpg2'
+
DEVNULL = open(os.devnull, 'wb')
gpg = subprocess.Popen(
- ('gpg','--with-fingerprint','--with-colons', keyfile),
+ (gpg_bin,'--with-fingerprint','--with-colons', keyfile),
stdout=subprocess.PIPE, stderr=DEVNULL)
out = gpg.communicate()
DEVNULL.close()
More information about the Pgp-tools-commit
mailing list