<commit_before># -*- python -*-
# ex: set syntax=python:

# This is a sample buildmaster config file. It must be installed as
# 'master.cfg' in your buildmaster's base directory.

# This is the dictionary that the buildmaster pays attention to. We also use
# a shorter alias to save typing.
c = BuildmasterConfig = {}

rust_git = 'git://github.com/mozilla/rust.git'

all_branches = ["master", "incoming", "try",
                "snap-stage3", "dist-snap"]

quick_platforms = ["mac", "linux", "win"]
full_platforms = quick_platforms + ["bsd"]
snap_platforms = full_platforms
dist_platforms = ["linux", "win"]
doc_platform = "linux"

####### BUILDSLAVES

# The 'slaves' list defines the set of recognized buildslaves. Each element is
# a BuildSlave object, specifying a unique slave name and password.  The same
# slave name and password must be configured on the slave.
from buildbot.buildslave import BuildSlave

c['slaves'] = []
for line in open("slave-list.txt"):
    if line.startswith("#"):
        continue
    fields = line.split()
    if len(fields) != 2:
        continue
    c['slaves'].append(BuildSlave(fields[0], fields[1]))


# We listen for slaves only on localhost; there should be an stunnel
# loopback forwarding to here.

c['slavePortnum'] = "tcp:9989:interface=127.0.0.1"

####### CHANGESOURCES

# the 'change_source' setting tells the buildmaster how it should find out
# about source code changes.

from buildbot.changes.gitpoller import GitPoller

main_sources = [GitPoller(rust_git,
                          workdir='gitpoller-workdir-%s' % b,
                          branch=b,
                          pollinterval=60) for b in all_branches]

c['change_source'] = main_sources

####### SCHEDULERS

# Configure the Schedulers, which decide how to react to incoming changes.

from buildbot.schedulers.basic import AnyBranchScheduler
from buildbot.changes import filter

try_sched = AnyBranchScheduler(
    name="try-quick-sched",
    change_filter=filter.ChangeFilter(branch='try'),
    treeStableTimer=None,
    builderNames=["quick-" + p for p in quick_platforms])

incoming_sched = AnyBranchScheduler(
    name="incoming-quick-sched",
    change_filter=filter.ChangeFilter(branch='incoming'),
    treeStableTimer=5*60,
    builderNames=["quick-" + p for p in quick_platforms])

full_sched = AnyBranchScheduler(
    name="full-sched",
    change_filter=filter.ChangeFilter(branch=['master',
                                              'incoming']),
    treeStableTimer=30*60,
    builderNames=["full-" + p for p in full_platforms])

doc_sched = AnyBranchScheduler(
    name="doc-sched",
    change_filter=filter.ChangeFilter(branch='master'),
    treeStableTimer=30*60,
    builderNames=["doc"])

snap_sched = AnyBranchScheduler(
    name="snap3-sched",
    change_filter=filter.ChangeFilter(branch='snap-stage3'),
    treeStableTimer=None,
    builderNames=["snap3-" + p for p in snap_platforms])

dist_sched = AnyBranchScheduler(
    name="dist-sched",
    change_filter=filter.ChangeFilter(branch='dist-snap'),
    treeStableTimer=None,
    builderNames=["dist-" + p for p in dist_platforms])

c['schedulers'] = [
try_sched,
incoming_sched,
full_sched,
doc_sched,
snap_sched,
dist_sched
]

####### BUILDERS

# The 'builders' list defines the Builders, which tell Buildbot how to perform a build:
# what steps, and which slaves can execute them.  Note that any particular build will
# only take place on one slave.

from buildbot.process.factory import BuildFactory
from buildbot.steps.source.git import Git
from buildbot.steps.shell import ShellCommand, Configure, Compile, Test
from buildbot.config import BuilderConfig

def do_build(platform,
             mk_targets=None,
             cfg_args=[],
             full_meth=None):
    global rust_git
    f = BuildFactory()

    # This is required to trigger certain workarounds
    # done slave-side by buildbot. In particular omitting
    # the PWD variable with an unmangled pathname.
    env = None;
    if "win" in platform:
        env = {"MACHTYPE": "i686-pc-msys"}

    if full_meth != None:
        f.addStep(Git(repourl=rust_git,
                      progress=True,
                      retryFetch=True,<commit_msg>add MSYSTEM<commit_after># -*- python -*-
# ex: set syntax=python:

# This is a sample buildmaster config file. It must be installed as
# 'master.cfg' in your buildmaster's base directory.

# This is the dictionary that the buildmaster pays attention to. We also use
# a shorter alias to save typing.
c = BuildmasterConfig = {}

rust_git = 'git://github.com/mozilla/rust.git'

all_branches = ["master", "incoming", "try",
                "snap-stage3", "dist-snap"]

quick_platforms = ["mac", "linux", "win"]
full_platforms = quick_platforms + ["bsd"]
snap_platforms = full_platforms
dist_platforms = ["linux", "win"]
doc_platform = "linux"

####### BUILDSLAVES

# The 'slaves' list defines the set of recognized buildslaves. Each element is
# a BuildSlave object, specifying a unique slave name and password.  The same
# slave name and password must be configured on the slave.
from buildbot.buildslave import BuildSlave

c['slaves'] = []
for line in open("slave-list.txt"):
    if line.startswith("#"):
        continue
    fields = line.split()
    if len(fields) != 2:
        continue
    c['slaves'].append(BuildSlave(fields[0], fields[1]))


# We listen for slaves only on localhost; there should be an stunnel
# loopback forwarding to here.

c['slavePortnum'] = "tcp:9989:interface=127.0.0.1"

####### CHANGESOURCES

# the 'change_source' setting tells the buildmaster how it should find out
# about source code changes.

from buildbot.changes.gitpoller import GitPoller

main_sources = [GitPoller(rust_git,
                          workdir='gitpoller-workdir-%s' % b,
                          branch=b,
                          pollinterval=60) for b in all_branches]

c['change_source'] = main_sources

####### SCHEDULERS

# Configure the Schedulers, which decide how to react to incoming changes.

from buildbot.schedulers.basic import AnyBranchScheduler
from buildbot.changes import filter

try_sched = AnyBranchScheduler(
    name="try-quick-sched",
    change_filter=filter.ChangeFilter(branch='try'),
    treeStableTimer=None,
    builderNames=["quick-" + p for p in quick_platforms])

incoming_sched = AnyBranchScheduler(
    name="incoming-quick-sched",
    change_filter=filter.ChangeFilter(branch='incoming'),
    treeStableTimer=5*60,
    builderNames=["quick-" + p for p in quick_platforms])

full_sched = AnyBranchScheduler(
    name="full-sched",
    change_filter=filter.ChangeFilter(branch=['master',
                                              'incoming']),
    treeStableTimer=30*60,
    builderNames=["full-" + p for p in full_platforms])

doc_sched = AnyBranchScheduler(
    name="doc-sched",
    change_filter=filter.ChangeFilter(branch='master'),
    treeStableTimer=30*60,
    builderNames=["doc"])

snap_sched = AnyBranchScheduler(
    name="snap3-sched",
    change_filter=filter.ChangeFilter(branch='snap-stage3'),
    treeStableTimer=None,
    builderNames=["snap3-" + p for p in snap_platforms])

dist_sched = AnyBranchScheduler(
    name="dist-sched",
    change_filter=filter.ChangeFilter(branch='dist-snap'),
    treeStableTimer=None,
    builderNames=["dist-" + p for p in dist_platforms])

c['schedulers'] = [
try_sched,
incoming_sched,
full_sched,
doc_sched,
snap_sched,
dist_sched
]

####### BUILDERS

# The 'builders' list defines the Builders, which tell Buildbot how to perform a build:
# what steps, and which slaves can execute them.  Note that any particular build will
# only take place on one slave.

from buildbot.process.factory import BuildFactory
from buildbot.steps.source.git import Git
from buildbot.steps.shell import ShellCommand, Configure, Compile, Test
from buildbot.config import BuilderConfig

def do_build(platform,
             mk_targets=None,
             cfg_args=[],
             full_meth=None):
    global rust_git
    f = BuildFactory()

    # This is required to trigger certain workarounds
    # done slave-side by buildbot. In particular omitting
    # the PWD variable with an unmangled pathname.
    env = None;
    if "win" in platform:
        env = {"MACHTYPE": "i686-pc-msys",
               "MSYSTEM": "MINGW32"}

    if full_meth != None:
        f.addStep(Git(repourl=rust_git,
                      progress=True,
                      retryFetch=True,
{'fraction_non_alphanumeric': 0.10999408633944412, 'fraction_numerical': 0.008042578356002365, 'mean_word_length': 3.5050612679808206, 'pattern_counts': {'":': 3, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6154545', 'n_tokens_mistral': 2613, 'n_tokens_neox': 2554, 'n_words': 720}