本文整理汇总了Python中buildbot.process.step.ShellCommand类的典型用法代码示例。如果您正苦于以下问题:Python ShellCommand类的具体用法?Python ShellCommand怎么用?Python ShellCommand使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了ShellCommand类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: start
def start(self):
urlGetter = LatestFileURL(self.url, self.filenameSearchString)
self.filename = urlGetter.getLatestFilename()
self.fileURL = self.url + self.filename
if self.branch:
self.setProperty("fileURL", self.fileURL)
self.setProperty("filename", self.filename)
self.setCommand(["wget", "-nv", "-N", self.fileURL])
ShellCommand.start(self)
示例2: __init__
def __init__(self, **kwargs):
self.filename = ""
self.branch = ""
if 'branch' in kwargs:
self.branch = kwargs['branch']
if 'filename' in kwargs:
self.filename = kwargs['filename']
if not 'command' in kwargs:
kwargs['command'] = ["tar", "-zvxf"]
ShellCommand.__init__(self, **kwargs)
示例3: __init__
def __init__(self, **kwargs):
if not 'platform' in kwargs:
return FAILURE
self.platform = kwargs['platform']
if 'dir' in kwargs:
self.dir = kwargs['dir']
if self.platform.startswith('win'):
self.command = r'if not exist ' + self.dir + r' mkdir ' + self.dir
else:
self.command = ['mkdir', '-p', self.dir]
ShellCommand.__init__(self, **kwargs)
示例4: __init__
def __init__(self, **kwargs):
self.flunkOnFailure = True
self.warnOnWarnings = True
self.warnOnFailure = True
if 'buildType' in kwargs:
self.buildType = kwargs['buildType']
else:
self.buildType = "opt"
if 'branch' in kwargs:
self.branch = kwargs['branch']
else:
self.branch = "1.9.0"
ShellCommand.__init__(self, **kwargs)
示例5: evaluateCommand
def evaluateCommand(self, cmd):
superResult = ShellCommand.evaluateCommand(self, cmd)
if SUCCESS != superResult:
return FAILURE
if None != re.search('ERROR', cmd.logs['stdio'].getText()):
return FAILURE
return SUCCESS
示例6: evaluateCommand
def evaluateCommand(self, cmd):
superResult = ShellCommand.evaluateCommand(self, cmd)
if SUCCESS != superResult:
return WARNINGS
if re.search('UNEXPECTED', cmd.logs['stdio'].getText()):
return WARNINGS
return SUCCESS