diff scripts/notify-roundup/notify-roundup.py @ 4175:67c03ee5af93 gsoc-2009

Trying some fixes
author Pygi <pygi@users.sourceforge.net>
date Tue, 07 Jul 2009 15:01:28 +0000
parents 200d32b89f9f
children 0c3e9fca71fe
line wrap: on
line diff
--- a/scripts/notify-roundup/notify-roundup.py	Tue Jul 07 14:56:21 2009 +0000
+++ b/scripts/notify-roundup/notify-roundup.py	Tue Jul 07 15:01:28 2009 +0000
@@ -49,10 +49,19 @@
     cfg = ConfigParser.ConfigParser()
     cfg.read(sys.argv[1])
     repos_dir = sys.argv[2]
-    revision = int(sys.argv[3])
+
     
     vcs_type = cfg.get('vcs', 'type')
     
+    if vcs_type == 'svn':
+        revision = int(sys.argv[3])
+    elif vcs_type == 'hg':
+        rev_type = sys.argv[3].split(':')
+        revision = rev_type(1)
+        logger.debug(revision)
+    else:
+        logging.error('something wen\'t wrong')
+        
     # get a handle on the revision in the VCS repository
     if vcs_type == 'svn':
         repos = SVNRepository(repos_dir, revision, pool)

Roundup Issue Tracker: http://roundup-tracker.org/