# find feeds
feeds = []
+feedbranches = dict()
from buildbot.changes.gitpoller import GitPoller
c['change_source'] = []
feeds.append(parts)
url = parts[2].strip().split(';')
branch = url[1] if len(url) > 1 else 'master'
+ feedbranches[url[0]] = branch
c['change_source'].append(GitPoller(url[0], branch=branch, workdir='%s/%s.git' %(os.getcwd(), parts[1]), pollinterval=300))
# Configure the Schedulers, which decide how to react to incoming changes. In this
# case, just kick off a 'basebuild' build
+def branch_change_filter(change):
+ return change.branch == feedbranches[change.repository]
+
from buildbot.schedulers.basic import SingleBranchScheduler
from buildbot.schedulers.forcesched import ForceScheduler
from buildbot.changes import filter
c['schedulers'] = []
c['schedulers'].append(SingleBranchScheduler(
name="all",
- change_filter=filter.ChangeFilter(branch='master'),
+ change_filter=filter.ChangeFilter(filter_fn=branch_change_filter),
treeStableTimer=60,
builderNames=archnames))