[Treepkg-commits] r503 - trunk/treepkg

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Tue Jan 11 17:04:05 CET 2011


Author: bricks
Date: 2011-01-11 17:04:05 +0100 (Tue, 11 Jan 2011)
New Revision: 503

Modified:
   trunk/treepkg/subversion.py
Log:
fix issue if baserev is not a corresponding revision number
(changed since kdepim is migrated to git)


Modified: trunk/treepkg/subversion.py
===================================================================
--- trunk/treepkg/subversion.py	2011-01-11 15:52:40 UTC (rev 502)
+++ trunk/treepkg/subversion.py	2011-01-11 16:04:05 UTC (rev 503)
@@ -346,6 +346,14 @@
             pass
         return urlrev
 
+    def log_xml(self, url):
+        """Return the log in XML of the repository since the copy
+        """
+        args = ["--stop-on-copy",
+                "--verbose",
+                "--xml"]
+        return run.capture_output(cmdexpand("svn log @args $url", **locals()))
+
     def tag_pkg_parameters(self, tag_url):
         # FIXME: Don't hardcore svn tag path and regex
         match = re.search(r"/enterprise[^.]*\.[^.]*\."
@@ -353,8 +361,9 @@
                           tag_url)
         if match:
             date = match.group("date")
+            # baserev is time since git migration
             baserev = match.group("baserev")
-            xml_log = log_xml(tag_url, baserev)
+            xml_log = self.log_xml(tag_url)
             revisions = extract_tag_revisions(xml_log)
             tag_change_count = len(revisions)
             return (date, tag_change_count)



More information about the Treepkg-commits mailing list