

See Specifying command and arguments section for examples and more details in general. When using a shell it is possible to give the whole command to execute as a single string. Because of these problems, it is recommended to use the shell only when absolutely necessary. Having a shell between the actually started process and this library can also interfere communication with the process such as stopping it and reading its outputs. It allows using the shell capabilities, but can also make the process invocation operating system dependent. Giving the shell argument any non-false value, such as shell=True, changes the program to be executed in a shell. You can, however, run shell scripts and batch files without using a shell. By default shell is not used, which means that shell specific commands, like copy and dir on Windows, are not available. The shell argument specifies whether to run the process in a shell or not.

Note that because **configuration is passed using name=value syntax, possible equal signs in other arguments passed to Run Process and Start Process must be escaped with a backslash like name\=value. New in RF 4.1.2.Įncoding to use when reading command outputs. Path of a file where to write standard error.Ĭonfigure process standard input. Path of a file where to write standard output. Overrides the named environment variable(s) only. Specifies environment variables given to the process.

Specifies whether to run the command in shell or not. When using this approach, the caller is responsible on escaping. The command can then contain multiple commands to be run together. When running processes in shell, it is also possible to give the whole command to execute as a single string. Notice that if a command accepts options that themselves accept values, these options and their values must be given as separate arguments. This makes usage convenient and also allows these keywords to automatically escape possible spaces and other special characters in commands and arguments. Waiting started process to complete using Wait For Process or stopping them with Terminate Process or Terminate All Processes.īoth Run Process and Start Process accept the command to execute and all arguments passed to the command as separate arguments.Starting processes on background using Start Process.Running processes in system and waiting for their completion using Run Process keyword.This library utilizes Python's subprocess module and its Popen class. Robot Framework library for running processes.
