3. Operands#
3.1. Operand LOGICIEL#
◊ LOGICIEL = exe_name
Name of the command or executable to call. It is a character string (between “), you must specify the full path to reach the executable.
3.2. Keyword ARGUMENT#
◊ ARGUMENT = l_arg
Allows you to define the list of arguments passed to the executable. Each element in the list corresponds to an argument supplied to the executable. If an argument contains a space, the executable will retrieve a character string containing the space (see keyword SHELL).
3.3. Keyword SHELL#
◊ SHELL = 'OUI'/'NON'
The best practice is to execute a program (keyword LOGICIEL) with a list of arguments (keyword ARGUMENT). We then leave SHELL at its default value which is equal to “NON”.
Sometimes, you want to execute not a program to which you pass arguments but a complete command line (for example starting with an if test). In this case, you should use SHELL =” NON “. The LOGICIEL keyword and any additional ARGUMENT [s] are attached with space to compose the complete command line.
See the Python subprocess module documentation for the pitfalls of SHELL =” NON “(False).
3.4. Operand INFO#
◊ INFO = info
In the case where INFO =2, the messages coming from the executed command are printed in the file MESSAGE. This is the by default value. This keeps track of the execution.
3.5. Operand CODE_RETOUR_MAXI#
◊ CODE_RETOUR_MAXI = icode
Maximum value of the return code returned by the command or software that is tolerated to consider that the execution went well. By default this value is 0, if it is set to —1, the return code of the command is ignored.