[SCM] build.samba.org - branch master updated

Jelmer Vernooij jelmer at samba.org
Sat Nov 13 06:36:35 MST 2010


The branch, master has been updated
       via  c868b29 Allow limiting the number of revisions that we look back.
      from  de84a30 Provide GitBranch.authors.

http://gitweb.samba.org/?p=build-farm.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit c868b2951d467200f728c15049f5099cec5bc98d
Author: Jelmer Vernooij <jelmer at samba.org>
Date:   Sat Nov 13 14:36:29 2010 +0100

    Allow limiting the number of revisions that we look back.

-----------------------------------------------------------------------

Summary of changes:
 buildfarm/history.py |    6 ++++--
 web/build.py         |    3 ++-
 2 files changed, 6 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildfarm/history.py b/buildfarm/history.py
index 1c96120..383782b 100644
--- a/buildfarm/history.py
+++ b/buildfarm/history.py
@@ -29,11 +29,13 @@ from dulwich.repo import Repo
 class Branch(object):
     """A version control branch."""
 
-    def authors(self):
+    def authors(self, limit=None):
         """Determine all authors that have contributed to this project.
         """
         ret = set()
-        for rev in self.log():
+        for i, rev in enumerate(self.log()):
+            if i == limit:
+                break
             ret.add(rev.author)
         return ret
 
diff --git a/web/build.py b/web/build.py
index d933554..88e99aa 100755
--- a/web/build.py
+++ b/web/build.py
@@ -52,6 +52,7 @@ basedir = os.path.abspath(os.path.join(webdir, ".."))
 
 UNPACKED_BASE = "http://svn.samba.org/ftp/unpacked"
 GITWEB_BASE = "http://gitweb.samba.org"
+HISTORY_HORIZON = 1000
 
 # this is automatically filled in
 deadhosts = []
@@ -875,7 +876,7 @@ class RecentCheckinsPage(BuildFarmPage):
     def render(self, myself, tree, author=None):
         t = self.buildfarm.trees[tree]
         authors = set(["ALL"])
-        authors.update(t.get_branch().authors(tree))
+        authors.update(t.get_branch().authors(limit=HISTORY_HORIZON))
 
         yield "<h2>Recent checkins for %s (%s branch %s)</h2>\n" % (
             tree, t.scm, t.branch)


-- 
build.samba.org


More information about the samba-cvs mailing list