|
#1
|
|||
|
|||
Multipule Build Process ~ Best Practice
Just a general question about multipule builds using one script.
We have 3 systems to build different versions to at different times. SIT, QA and production. There are a few differences to each system build, mostly where the code is located within VSS, the working directory, where the output goes, and who gets notified about the builds fail or success. We currently have one script chained to several scrpits to make this all work on the SIT level. We are wanting to take this same script and make it send off the QA and Production builds. This is where the question comes. There are 3 ways that I see we can go about this. 1. Copy the scripts rename the file with a corresponding name IE build1SIT, build1QA, build1PR, Etc... 2. Use the same script but have the batch file calling VBP to use different sets of Macros. 3. Use the same scripts with repeating steps that based upon a macro passed from the batch file that will tell it to conditionally build the correct group/steps. Number 1 is purly not going to work as I refuse to put that much work into complicating things. Number 2 is the option I favor, but it still means keeping tack of 3 batch files and 3 macro lists. Number 3 is what my boss appears to like the best. I see this as overflowing the build script with more steps then are needed and having to set macros each time. Looking over this, I guess there is a fourth option of a hybrid of 2 and 3. In the end the question comes down to does anyone have any input on this from experience, or can suggest another method that may work? TIA T. Miller |
#2
|
|||
|
|||
#2 sounds the best. You can define a default behavior by creating project macros, then override these on the command-line for the other versions. The VisBuildPro.bld sample in the Samples\VisBuildPro folder demonstrates this (and the Master.bld and BuilderLauncher samples demonstrate different ways of launching with override values).
|
#3
|
|||
|
|||
I am struggling with this concept too.
I'm not proficient enough to follow the example you mentioned. May I ask for a different one... We use Delphi. A Delphi step has has a versions tab which says "set or increment the version number Yes/No". If I had two build steps for every Delphi package, this is obvious. One would be Yes and one would be No. I would run a different step based on a macro value. But then I have twice the steps, and duplication to beware of. Sometimes I want to set the version, and sometimes not. I'm not seeing how to change this option based on some other macro value. Many thanks in advance. |
#4
|
|||
|
|||
Use a field override to specify a macro value for a radio button or checkbox field on a step:
http://www.visualbuild.com/Manual/?a...ldoverride.htm The attached sample demonstrates this for the version setting on a Make Delphi action. A project macro VERSEL configures the default of 0 (don't change version). This can be overriden by setting a temporary macro VERSEL value of 1 (increment) or 2 (set), which is demonstrated by the unchecked steps at the beginning of the project (you can right-click and Rebuild Selected on one of these to test). You could prompt for the value within the build or call your project from a Scheduled Task or another VBP project, etc., passing in the appropriate values. See the following help topics for more details: http://www.visualbuild.com/Manual/?promptsample.htm http://www.visualbuild.com/Manual/?v...projaction.htm http://www.visualbuild.com/Manual/?schedulingbuilds.htm |
|
|