![]() |
OpenMake Meister |
Once a Workflow has been defined and saved you can execute it in a command line fashion with omcmdline.jar. omcmdline.jar can be found in the bin directory under the root install of the Command Line Client. When executed, omcmdline.jar will call the Workflow exactly as it is defined in the Workflow Explorer.
Because omcmdline.jar is a java based utility, it will need to be executed by your locally installed Java JRE. The standard arguments for executing a jar file are:
java –cp <classpath libraries> <class to execute> <arguments to pass to class>
In order to execute omcmdline.jar then, the java syntax will be:
java –cp <full path to omcmdline.jar> com.openmake.cmdline.Main <omcmdline arguments>
The syntax for calling a Workflow at the command line is as follows:
java –cp <command line client install location>\bin\omcmdline.jar com.openmake.cmdline.Main omcmdline.jar -build <Build_Job>, <Build_Job>
*Note: If Public and Private Workflows share the same name, the Public takes precedence.
Workflows run by omcmdline.jar will also supply a return code after they have completed so that this information can be processed in batch scripts. The detail of what specifically caused the error return code will be printed in the log file.
It is also possible to execute Workflows from the command line in a parameterized fashion. This means that numerous options can be passed into the execution of a command line Workflow to customize its behavior, including setting environment variables, specifying how the logs will appear in the Workflow Log Explorer.
More: