[Buildbot-commits] buildbot/buildbot/steps source.py,1.7,1.8

Brian Warner warner at users.sourceforge.net
Sun Sep 30 02:36:36 UTC 2007


Update of /cvsroot/buildbot/buildbot/buildbot/steps
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv31070/buildbot/steps

Modified Files:
	source.py 
Log Message:
[project @ Mercurial: use last change to compute source revision. Closes #103.]

Original author: warner at lothar.com
Date: 2007-09-30 02:36:07+00:00

Index: source.py
===================================================================
RCS file: /cvsroot/buildbot/buildbot/buildbot/steps/source.py,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- source.py	3 Jul 2007 19:17:49 -0000	1.7
+++ source.py	30 Sep 2007 02:36:34 -0000	1.8
@@ -890,6 +890,15 @@
         cmd = LoggedRemoteCommand("hg", self.args)
         self.startCommand(cmd)
 
+    def computeSourceRevision(self, changes):
+        if not changes:
+            return None
+        # without knowing the revision ancestry graph, we can't sort the
+        # changes at all. So for now, assume they were given to us in sorted
+        # order, and just pay attention to the last one. See ticket #103 for
+        # more details.
+        return changes[-1].revision
+
 
 class P4(Source):
     """ P4 is a class for accessing perforce revision control"""





More information about the Commits mailing list