Adding a Script

Whether you are creating a build configuration script or a transition script, you can select any of the following three ways to add a script:

- Input script content manually

- Use a Dimensions-controlled file as a script

- Use a file in the build area as a script

You can use each of these methods whether you are creating a Pre-Script, Main Script, or Post-Script, or Clean-Up Script.

NOTE When you create a new target, you must fill out at least the name of the target before you can move to the Script page of the Create New Target Wizard.

If you are creating a transition script, you can also select Use the build configuration main script.

Entering Content Manually

You can enter the content of the script manually. This method is best when you are creating test configurations, or when the content of the build script is simple enough so that you can type it from memory.

To enter the content of the script manually:

1. From the Script page of the Create New Target wizard, select Input script content manually as a script from the drop-down list. The Script Content text field appears.

2. Enter the content of the script into the Script Content area.

NOTE Dimensions CM looks for the build script and any other files in the build directory. To refer to files that are elsewhere, specify the location of those files in the script.

3. Click Next to define build options, or click Finish to complete the target definition.

Using a Dimensions-Controlled File

NOTE If you select a Dimensions-controlled file as a script, be aware that the file is pushed to the build area if you are using a work area. If you are using a deployment area, Dimensions Build assumes that the script has already been deployed to that area.

To use a Dimensions-controlled file as a script:

1. From the Script page of the Create New Target wizard, select Use Dimensions-controlled file as a script from the drop-down list. A text field appears, with a browse button next to it.

2. Click the browse button. The Select File from Dimensions dialog box opens.

3. Expand the Projects or Baselines tree to display the available files.

4. Select the Dimensions-controlled file.

5. Click OK. The specification for the file is displayed in the text field for the script name.

6. Click Next to define build options, or click Finish to complete the target definition.

Using a File in the Build Area

To use a file in the build area as a script:

1. From the Script page of the Create New Target wizard, select Use a file in the build area as a script from the list. A text field appears.

2. If you already know the name of the file containing the build script, enter it in the text field of the dialog box; otherwise, click Browse to display the Build Area Browser.

3. Select the file from the browser, then click Select. The file is displayed in the Edit Transition Script dialog box.

4. Click Next to define build options, or click Finish to complete the target definition.

Using the Build Configuration Global Script

To use the build configuration global script:

1. From the Script page of the Create New Target wizard, select Same as build configuration global script from the list.

2. Click Next to define build options, or click Finish to complete the target definition.