Ticket #277: fixMercurialUpdate.diff
| File fixMercurialUpdate.diff, 1.7 kB (added by bhearsum, 8 months ago) |
|---|
-
old-upstream-buildbot-mirror/buildbot/slave/commands.py
old new 2204 2204 if os.path.exists(os.path.join(self.builder.basedir, 2205 2205 self.srcdir, ".buildbot-patched")): 2206 2206 return False 2207 # like Darcs, to check out a specific (old) revision, we have to do a2208 # full checkout. TODO: I think 'hg pull' plus 'hg update' might work2209 if self.revision:2210 return False2211 2207 return os.path.isdir(os.path.join(self.builder.basedir, 2212 2208 self.srcdir, ".hg")) 2213 2209 2214 2210 def doVCUpdate(self): 2215 2211 d = os.path.join(self.builder.basedir, self.srcdir) 2216 command = [self.vcexe, 'pull', '--update', '--verbose'] 2212 command = [self.vcexe, 'pull', '--verbose'] 2213 c = ShellCommand(self.builder, command, d, 2214 sendRC=False, timeout=self.timeout, 2215 keepStdout=True) 2216 self.command = c 2217 d = c.start() 2218 d.addCallback(self._doUpdate) 2219 return d 2220 2221 def _doUpdate(self, res): 2222 d = os.path.join(self.builder.basedir, self.srcdir) 2223 # 'hg pull' has already been run, now we need to update to a specific 2224 # revision if specified, or to the tip otherwise 2225 command = [self.vcexe, 'update'] 2217 2226 if self.args['revision']: 2218 2227 command.extend(['--rev', self.args['revision']]) 2219 2228 c = ShellCommand(self.builder, command, d,
![[Buildbot Logo]](/trac/chrome/site/header-text-transparent.png)