Skip to content


Subversion checkout URL

You can clone with
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base: 183b154150
compare: f24a033e49
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 1 contributor
Commits on May 14, 2012
@tlyu tlyu Support multiple push-to repositories
Add support for multiple push-to repositories, by calling
post-receive-push once per remote, looping over multiple values of
@tlyu tlyu Update buildbot for Git repository f24a033
Showing with 19 additions and 24 deletions.
  1. +16 −21 buildbot/master.cfg
  2. +3 −3 githooks/post-receive
37 buildbot/master.cfg
@@ -42,15 +42,10 @@ c['slavePortnum'] = 'tcp:9989:interface='
# put here: there are several in buildbot/changes/*.py to choose from.
from buildbot.changes.pb import PBChangeSource
-from buildbot.changes.svnpoller import SVNPoller, split_file_branches
c['change_source'] = []
-# Poll SVN hourly.
- split_file=split_file_branches,
- pollinterval=3600))
# For example, if you had CVSToys installed on your repository, and your
# CVSROOT/freshcfg file had an entry like this:
#pb = ConfigurationSet([
@@ -88,18 +83,18 @@ def buildernames(branch, platforms):
from buildbot.scheduler import Scheduler
c['schedulers'] = []
-c['schedulers'].append(Scheduler(name="trunk", branch=None,
- treeStableTimer=0,
- builderNames=buildernames('trunk', platforms)))
+c['schedulers'].append(Scheduler(name="master", branch='master',
+ treeStableTimer=300,
+ builderNames=buildernames('master', platforms)))
-for branch in ('krb5-1-9', 'krb5-1-10'):
- c['schedulers'].append(Scheduler(name=branch, branch='branches/'+branch,
- treeStableTimer=0,
+for branch in ('krb5-1.9', 'krb5-1.10'):
+ c['schedulers'].append(Scheduler(name=branch, branch=branch,
+ treeStableTimer=300,
builderNames=buildernames(branch, platforms)))
# Documentation builder
-c['schedulers'].append(Scheduler(name="trunk-doc", branch=None,
- treeStableTimer=0, builderNames=['trunk-doc']))
+c['schedulers'].append(Scheduler(name="master-doc", branch='master',
+ treeStableTimer=300, builderNames=['master-doc']))
####### BUILDERS
@@ -123,24 +118,24 @@ c['schedulers'].append(Scheduler(name="trunk-doc", branch=None,
from buildbot.process import factory
from buildbot.locks import SlaveLock
-from buildbot.steps.source import SVN
+from buildbot.steps.source import Git
from import Configure, Compile, ShellCommand, Test
from buildbot.steps.transfer import FileUpload
-anonsvn = "svn://"
+anonrepo = "git://"
# Lock to avoid running "make check" in parallel on a single host.
# They will fail due to hardcoded port numbers.
testlock = SlaveLock("test")
f1 = factory.BuildFactory()
-f1.addStep(SVN(baseURL=anonsvn, defaultBranch="trunk", mode="clobber"))
+f1.addStep(Git(repourl=anonrepo, mode="clobber"))
f1.addStep(Configure(command="(cd src && util/reconf && ./configure)"))
f1.addStep(Compile(command="(cd src && make)"))
f1.addStep(Test(command="(cd src && make check)",
c['builders'] = []
-branches = ('trunk', 'krb5-1-9', 'krb5-1-10')
+branches = ('master', 'krb5-1.9', 'krb5-1.10')
for platform in platforms:
for branch in branches:
@@ -154,14 +149,14 @@ for platform in platforms:
# Documentation builder
f2 = factory.BuildFactory()
-f2.addStep(SVN(baseURL=anonsvn, defaultBranch="trunk", mode="clobber"))
+f2.addStep(Git(repourl=anonrepo, mode="clobber"))
f2.addStep(ShellCommand(command="(cd src/doc && make -f srcdir=. top_srcdir=.. PYTHON=python rsthtml)", description=["docs"], descriptionDone=["docs"], haltOnFailure=True))
f2.addStep(ShellCommand(command=["tar", "zcf", "rst_html.tgz", "doc/rst_html"], description="tar", descriptionDone="tar", haltOnFailure=True))
f2.addStep(FileUpload(slavesrc="rst_html.tgz", masterdest="~/master/rst_html.tgz"))
d = dict(factory=f2)
-d['name'] = 'trunk-doc'
-d['builddir'] = 'trunk-doc'
+d['name'] = 'master-doc'
+d['builddir'] = 'master-doc'
d['slavenames'] = ['v09']
6 githooks/post-receive
@@ -14,7 +14,7 @@ from hookutils import *
# RT or the notification list.
max_revs_per_ref = 50
-push_to = run(['git', 'config', 'hooks.push-to'])[0]
+push_to = run(['git', 'config', '--get-all', 'hooks.push-to'])
# Run a script from the hooks directory with the specified arguments.
def run_hook(name, args=[]):
@@ -63,5 +63,5 @@ for oldrev, newrev, refname in inputs:
if newrev != no_rev:
run_hook('post-receive-notify', ['newtag', shortname, newrev])
-if push_to:
- run_hook('post-receive-push', [push_to])
+for remote in push_to:
+ run_hook('post-receive-push', [remote])

No commit comments for this range

Something went wrong with that request. Please try again.