Building workspaces
You can build and deploy workspaces while you are working
in PowerBuilder, and from a command line.
In the development environment
In the development environment, you can specify how you want
the targets in your workspace to be built and deployed. Then you
can build individual targets or all the targets in the workspace. Table 1-3 summarizes where
you set up build and deploy options, and how you start builds.
| To do this | Do this |
|---|---|
| Set deploy options for a PowerScript target |
Select Properties from the pop-up menu for the target and select the Deploy tab. Check the box next to a project to build it when you select Deploy from the target’s pop-up menu. Use the arrows to set the order in which projects are built. Set options for each project in the target in the Project painter. |
| Set build and deploy options for a Web target |
Set up and activate deployment controllers on the Deploy page of the target’s properties dialog box. |
| Set build and deploy options for the workspace | Select Properties from the pop-up menu for the workspace and select the order in which targets should be built. You can check which projects and deploy configurations are currently selected on the Deploy Preview page. |
| Build, migrate, or deploy a selected PowerScript target |
Select Incremental Build, Full Build, Migrate, or Deploy from the pop-up menu for the target. Deploy builds the projects in the target in the order listed on the Deploy page of the target’s properties dialog box. |
| Build or deploy a selected Web target | Select Incremental Build or Full Build from the pop-up menu for the target to check HTML files for broken links and populate a build directory with their data, and copy other files to the build directory. Select Deploy to deploy the target using the deployment controllers marked as active on the Deploy page of the target’s properties dialog box. |
| Build or deploy all the targets in the workspace |
Select Incremental Build, Full Build, or Deploy from the pop-up menu for the workspace, from the Run menu, or from the PowerBar. |
From a command line
When you deploy or build a workspace from a command line,
PowerBuilder starts, completes the build, and exits as soon as the
operation is completed. To retain a log file for the session, you
can send the contents of the Output window to a file. Table 1-4 shows command-line
options for building and deploying targets and workspaces.
| Option | Description |
|---|---|
| /workspace workspacepath | Open the workspace workspacepath |
| /target targetpath | Open the target targetpath |
| /deploy | Deploy the workspace and exit |
| /fullbuild | Fully build the workspace and exit |
| /incrementalbuild | Incrementally build the workspace and exit |
| /output outputpath | Log the contents of the Output window to outputpath |
As with other command-line options, you need only use the
initial letter or letters of the option name as long as the option
is uniquely identified. The deploy, fullbuild,
and incrementalbuild options can be used only
with the workspace option. You need to create
projects and specify build and deploy options for the workspace
in PowerBuilder before you start a build from the command line.
Deploy builds the projects in the target in the order listed on
the Deploy page of the target’s properties dialog box.
Example
This example assumes that the location of the PowerBuilder
executable file is in your system path. It opens the workspace called
CDShop, builds and deploys the targets in the workspace according
to your specifications in the workspace and target properties, records
the content of the Output window in the file D: mpcdshop.out,
and exits PowerBuilder:
|
1 |
pb105 /w D:CDShopCDShop.pbw /d /out D: mpcdshop.out |
There are additional command-line options you can use to start
PowerBuilder. See “Using command line arguments”.