A <run> element is used within an <interface> element
to specify a named command to run. The command is defined later in
the same XML file. The <run> element is an empty element.
Attributes:
- condition
- Optional, in the form condition="function". The value of function is
an expression that evaluates to true or false. If it evaluates to
true, the command is run. If it evaluates to false, it is not run.
See Condition functions.
- command
- Required. It specifies name of a defined command to run. The command
is named and defined in a <command> element.
- dir
- Required. It specifies the directory in which to run the command.
The dir is interpreted as an extension of the path set in the server
resource that the command runs on.
- mode
- Optional. Specifies the run mode for the run command. The mode
attribute exec is used, which triggers the server
to start and immediately process commands.
Note: For Rational® Build
Forge® 8.0, only the default exec mode
is supported.
- params
- Required. It specifies parameters to pass to the command. Use
spaces to separate the parameters.
- server
- Required. It specifies the server resource to run the command
on. If it is set to null, the command is run on the server used by
the step that runs the adaptor. Use server="" to
set the server to null.
- timeout
- Required. It specifies how many seconds before the command times
out.
Example showing required attributes:
<run command="UpdateEnv" params="" server="" dir="/" timeout="360"/>
Example:
<run command="p4_changes" params="$LAST_RUN $FILESPEC $LAST_VER"
server="$P4CLIENT" dir="/" timeout="360"/>