* ./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
|
||||
|
||||
|
||||
def _commandTemplate ( self, tools, projectName, command ):
|
||||
def _commandTemplate ( self, tools, projects, command ):
|
||||
# Set or guess the various projects TOP environment variables.
|
||||
for project in self._projects:
|
||||
topVariable = "%s_TOP" % project.getName().upper()
|
||||
|
@ -287,7 +287,8 @@ class ProjectBuilder:
|
|||
if self._environment.has_key(topUserVariable):
|
||||
print "Transmitting %s = \"%s\"." % (topUserVariable,self._environment[topUserVariable])
|
||||
|
||||
if projectName:
|
||||
if projects:
|
||||
for projectName in projects:
|
||||
project = self.getProject ( projectName )
|
||||
if not project:
|
||||
print "[ERROR] No project of name \"%s\"." % projectName
|
||||
|
@ -300,6 +301,7 @@ class ProjectBuilder:
|
|||
self._orderTools ( tools )
|
||||
for project in self._projects:
|
||||
for tool in project.getActives():
|
||||
print "\nProcessing tool: \"%s\"." % tool
|
||||
getattr(self,command) ( tool )
|
||||
for tool in self._standalones:
|
||||
print "\nProcessing tool: \"%s\"." % tool
|
||||
|
@ -307,23 +309,23 @@ class ProjectBuilder:
|
|||
return
|
||||
|
||||
|
||||
def build ( self, tools, projectName ):
|
||||
self._commandTemplate ( tools, projectName, "_build" )
|
||||
def build ( self, tools, projects ):
|
||||
self._commandTemplate ( tools, projects, "_build" )
|
||||
return
|
||||
|
||||
|
||||
def svnStatus ( self, tools, projectName ):
|
||||
self._commandTemplate ( tools, projectName, "_svnStatus" )
|
||||
def svnStatus ( self, tools, projects ):
|
||||
self._commandTemplate ( tools, projects, "_svnStatus" )
|
||||
return
|
||||
|
||||
|
||||
def svnUpdate ( self, tools, projectName ):
|
||||
self._commandTemplate ( tools, projectName, "_svnUpdate" )
|
||||
def svnUpdate ( self, tools, projects ):
|
||||
self._commandTemplate ( tools, projects, "_svnUpdate" )
|
||||
return
|
||||
|
||||
|
||||
def svnCheckout ( self, tools, projectName ):
|
||||
self._commandTemplate ( tools, projectName, "_svnCheckout" )
|
||||
def svnCheckout ( self, tools, projects ):
|
||||
self._commandTemplate ( tools, projects, "_svnCheckout" )
|
||||
return
|
||||
|
||||
|
||||
|
@ -373,7 +375,7 @@ if __name__ == "__main__":
|
|||
parser.add_option ( "--no-cache" , action="store_true", dest="noCache" )
|
||||
parser.add_option ( "--svn-tag" , action="store" , type="string", dest="svnTag" )
|
||||
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" )
|
||||
# SVN repository relateds.
|
||||
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.svnTag: builder.svnTag = options.svnTag
|
||||
|
||||
if options.svnStatus: builder.svnStatus ( tools=options.tools, projectName=options.project )
|
||||
elif options.svnUpdate: builder.svnUpdate ( tools=options.tools, projectName=options.project )
|
||||
elif options.svnCheckout: builder.svnCheckout ( tools=options.tools, projectName=options.project )
|
||||
else: builder.build ( 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, projects=options.projects )
|
||||
elif options.svnCheckout: builder.svnCheckout ( tools=options.tools, projects=options.projects )
|
||||
else: builder.build ( tools=options.tools, projects=options.projects )
|
||||
|
||||
sys.exit ( 0 )
|
||||
|
|
Loading…
Reference in New Issue