* ./goodies:
- Bug: In buildCoriolis.py, when multiple projects where given on the command line, only the latest was processed. Now all projects are processeds. (in the order given on the command line so watch out!)
This commit is contained in:
parent
7e0d158a16
commit
3a25248804
|
@ -273,7 +273,7 @@ class ProjectBuilder:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def _commandTemplate ( self, tools, projectName, command ):
|
def _commandTemplate ( self, tools, projects, command ):
|
||||||
# Set or guess the various projects TOP environment variables.
|
# Set or guess the various projects TOP environment variables.
|
||||||
for project in self._projects:
|
for project in self._projects:
|
||||||
topVariable = "%s_TOP" % project.getName().upper()
|
topVariable = "%s_TOP" % project.getName().upper()
|
||||||
|
@ -287,7 +287,8 @@ class ProjectBuilder:
|
||||||
if self._environment.has_key(topUserVariable):
|
if self._environment.has_key(topUserVariable):
|
||||||
print "Transmitting %s = \"%s\"." % (topUserVariable,self._environment[topUserVariable])
|
print "Transmitting %s = \"%s\"." % (topUserVariable,self._environment[topUserVariable])
|
||||||
|
|
||||||
if projectName:
|
if projects:
|
||||||
|
for projectName in projects:
|
||||||
project = self.getProject ( projectName )
|
project = self.getProject ( projectName )
|
||||||
if not project:
|
if not project:
|
||||||
print "[ERROR] No project of name \"%s\"." % projectName
|
print "[ERROR] No project of name \"%s\"." % projectName
|
||||||
|
@ -300,6 +301,7 @@ class ProjectBuilder:
|
||||||
self._orderTools ( tools )
|
self._orderTools ( tools )
|
||||||
for project in self._projects:
|
for project in self._projects:
|
||||||
for tool in project.getActives():
|
for tool in project.getActives():
|
||||||
|
print "\nProcessing tool: \"%s\"." % tool
|
||||||
getattr(self,command) ( tool )
|
getattr(self,command) ( tool )
|
||||||
for tool in self._standalones:
|
for tool in self._standalones:
|
||||||
print "\nProcessing tool: \"%s\"." % tool
|
print "\nProcessing tool: \"%s\"." % tool
|
||||||
|
@ -307,23 +309,23 @@ class ProjectBuilder:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def build ( self, tools, projectName ):
|
def build ( self, tools, projects ):
|
||||||
self._commandTemplate ( tools, projectName, "_build" )
|
self._commandTemplate ( tools, projects, "_build" )
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def svnStatus ( self, tools, projectName ):
|
def svnStatus ( self, tools, projects ):
|
||||||
self._commandTemplate ( tools, projectName, "_svnStatus" )
|
self._commandTemplate ( tools, projects, "_svnStatus" )
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def svnUpdate ( self, tools, projectName ):
|
def svnUpdate ( self, tools, projects ):
|
||||||
self._commandTemplate ( tools, projectName, "_svnUpdate" )
|
self._commandTemplate ( tools, projects, "_svnUpdate" )
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def svnCheckout ( self, tools, projectName ):
|
def svnCheckout ( self, tools, projects ):
|
||||||
self._commandTemplate ( tools, projectName, "_svnCheckout" )
|
self._commandTemplate ( tools, projects, "_svnCheckout" )
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
|
@ -373,7 +375,7 @@ if __name__ == "__main__":
|
||||||
parser.add_option ( "--no-cache" , action="store_true", dest="noCache" )
|
parser.add_option ( "--no-cache" , action="store_true", dest="noCache" )
|
||||||
parser.add_option ( "--svn-tag" , action="store" , type="string", dest="svnTag" )
|
parser.add_option ( "--svn-tag" , action="store" , type="string", dest="svnTag" )
|
||||||
parser.add_option ( "--make" , action="store" , type="string", dest="makeArguments")
|
parser.add_option ( "--make" , action="store" , type="string", dest="makeArguments")
|
||||||
parser.add_option ( "--project" , action="store" , type="string", dest="project" )
|
parser.add_option ( "--project" , action="append" , type="string", dest="projects" )
|
||||||
parser.add_option ( "-t", "--tool" , action="append" , type="string", dest="tools" )
|
parser.add_option ( "-t", "--tool" , action="append" , type="string", dest="tools" )
|
||||||
# SVN repository relateds.
|
# SVN repository relateds.
|
||||||
parser.add_option ( "--svn-status" , action="store_true", dest="svnStatus" )
|
parser.add_option ( "--svn-status" , action="store_true", dest="svnStatus" )
|
||||||
|
@ -400,9 +402,9 @@ if __name__ == "__main__":
|
||||||
if options.makeArguments: builder.makeArguments = options.makeArguments
|
if options.makeArguments: builder.makeArguments = options.makeArguments
|
||||||
if options.svnTag: builder.svnTag = options.svnTag
|
if options.svnTag: builder.svnTag = options.svnTag
|
||||||
|
|
||||||
if options.svnStatus: builder.svnStatus ( tools=options.tools, projectName=options.project )
|
if options.svnStatus: builder.svnStatus ( tools=options.tools, projects=options.projects )
|
||||||
elif options.svnUpdate: builder.svnUpdate ( tools=options.tools, projectName=options.project )
|
elif options.svnUpdate: builder.svnUpdate ( tools=options.tools, projects=options.projects )
|
||||||
elif options.svnCheckout: builder.svnCheckout ( tools=options.tools, projectName=options.project )
|
elif options.svnCheckout: builder.svnCheckout ( tools=options.tools, projects=options.projects )
|
||||||
else: builder.build ( tools=options.tools, projectName=options.project )
|
else: builder.build ( tools=options.tools, projects=options.projects )
|
||||||
|
|
||||||
sys.exit ( 0 )
|
sys.exit ( 0 )
|
||||||
|
|
Loading…
Reference in New Issue