commit:     6d02096f1b8afbf3ed2126def65cfbe2d65d0237
Author:     Brian Dolbec <dolsen <AT> gentoo <DOT> org>
AuthorDate: Sun Dec 28 08:24:22 2014 +0000
Commit:     Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Tue Dec 30 21:42:26 2014 +0000
URL:        
http://sources.gentoo.org/gitweb/?p=proj/gentoo-keys.git;a=commit;h=6d02096f

gkeys/gkey.py: Separate uid string printing for list type output

---
 gkeys/gkeys/gkey.py | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/gkeys/gkeys/gkey.py b/gkeys/gkeys/gkey.py
index 463f007..130a5d5 100644
--- a/gkeys/gkeys/gkey.py
+++ b/gkeys/gkeys/gkey.py
@@ -18,7 +18,10 @@ GKEY_STRING = '''    ----------
     Name.........: %(name)s
     Nick.........: %(nick)s
     Keydir.......: %(keydir)s
-    UID..........: %(uid)s
+'''
+
+GKEY_UID = \
+'''    UID..........: %(uid)s
 '''
 
 GKEY_FINGERPRINTS = \
@@ -48,9 +51,10 @@ class GKEY(namedtuple('GKEY', ['nick', 'name', 'keydir', 
'keys', 'fingerprint',
             'name': self.name,
             'nick': self.nick,
             'keydir': self.keydir,
-            'uid': self.uid,
             }
         output = GKEY_STRING % gkey
+        for uid in self.uid:
+            output += GKEY_UID % {'uid': uid}
         for f in self.fingerprint:
             fingerprint = {'fingerprint': f, 'keyid': '0x' + f[-16:]}
             output += GKEY_FINGERPRINTS % fingerprint

Reply via email to