phase1: switch away from deprecated slave side Git step
[buildbot.git] / phase1 / master.cfg
index 2e7c195ff8bf0add79dc3d8d0f67fe9c53364c20..bbed0543df32a53d4731cfc1052e8ca80474445a 100644 (file)
@@ -96,10 +96,8 @@ if ini.has_option("gpg", "passfile"):
 targets = [ ]
 
 if not os.path.isdir(home_dir+'/source.git'):
-       subprocess.call(["git", "clone", "--depth=1", repo_url, home_dir+'/source.git'])
-       subprocess.call(["git", "checkout", repo_branch], cwd = home_dir+'/source.git')
+       subprocess.call(["git", "clone", "--depth=1", "--branch="+repo_branch, repo_url, home_dir+'/source.git'])
 else:
-       subprocess.call(["git", "checkout", repo_branch], cwd = home_dir+'/source.git')
        subprocess.call(["git", "pull"], cwd = home_dir+'/source.git')
 
 findtargets = subprocess.Popen([home_dir+'/dumpinfo.pl', 'targets'],
@@ -149,7 +147,7 @@ c['schedulers'].append(ForceScheduler(
 # only take place on one slave.
 
 from buildbot.process.factory import BuildFactory
-from buildbot.steps.source import Git
+from buildbot.steps.source.git import Git
 from buildbot.steps.shell import ShellCommand
 from buildbot.steps.shell import SetProperty
 from buildbot.steps.transfer import FileUpload
@@ -276,7 +274,11 @@ for target in targets:
                ))
 
        # check out the source
-       factory.addStep(Git(repourl=repo_url, branch=repo_branch, mode='update'))
+       factory.addStep(Git(
+               repourl = repo_url,
+               branch = repo_branch,
+               mode = 'incremental',
+               method = 'clean'))
 
        factory.addStep(ShellCommand(
                name = "rmtmp",