commit:     b485b703ab0926646a2822f3ba16323562cff99f
Author:     Brian Dolbec <dolsen <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 25 19:22:49 2014 +0000
Commit:     Brian Dolbec <brian.dolbec <AT> gmail <DOT> com>
CommitDate: Thu Dec 25 19:22:49 2014 +0000
URL:        
http://sources.gentoo.org/gitweb/?p=proj/gentoo-keys.git;a=commit;h=b485b703

gkeys-ldap: Update args use for the new category handling

---
 gkeys-ldap/bin/update-seeds.sh |  2 +-
 gkeys-ldap/gkeyldap/actions.py | 10 ++++------
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/gkeys-ldap/bin/update-seeds.sh b/gkeys-ldap/bin/update-seeds.sh
index 2d67c0e..717636a 100755
--- a/gkeys-ldap/bin/update-seeds.sh
+++ b/gkeys-ldap/bin/update-seeds.sh
@@ -28,7 +28,7 @@ fi
 
 echo " *** Fetching new seeds from LDAP"
 cd ${GKEYS_DIR}
-gkeys-ldap -c ${GKEYS_CONF} updateseeds || die "Seed file generation failed... 
aborting"
+gkeys-ldap -c ${GKEYS_CONF} updateseeds -C gentoo-devs || die "Seed file 
generation failed... aborting"
 
 echo " *** Checking if seed files are up-to-date"
 if ! diff -q ${GKEYS_DIR}/${GKEYS_SEEDS} ${API_DIR}/${API_SEEDS} > /dev/null 
;then

diff --git a/gkeys-ldap/gkeyldap/actions.py b/gkeys-ldap/gkeyldap/actions.py
index ee06673..815950d 100644
--- a/gkeys-ldap/gkeyldap/actions.py
+++ b/gkeys-ldap/gkeyldap/actions.py
@@ -21,8 +21,8 @@ from gkeys.fileops import updatefiles
 Available_Actions = ['ldapsearch', 'updateseeds']
 
 Action_Options = {
-    'ldapsearch': ['fingerprint', 'mail', 'name', 'nick', 'seedfile', 
'status'],
-    'updateseeds': ['fingerprint', 'mail', 'name', 'nick', 'seedfile', 
'status'],
+    'ldapsearch': ['fingerprint', 'mail', 'name', 'nick', 'status'],
+    'updateseeds': ['fingerprint', 'mail', 'name', 'nick', 'category', 
'status'],
 }
 
 
@@ -85,10 +85,8 @@ class Actions(object):
         info = l.result2dict(results, 'uid')
         self.logger.debug(
             "MAIN: _action_updateseeds; got results :) converted to info")
-        if args.seedfile:
-            filename = self.config.get('seeds', args.seedfile) + '.new'
-        elif args.file:
-            filename = arg.file
+        if args.category:
+            filename = self.config.get('seeds', args.category) + '.new'
         if not self.create_seedfile(info, filename):
             self.logger.error("Developer seed file update failure: "
                 "Original seed file is intact & untouched.")

Reply via email to