This function allows you to interact with the operating system terminal or console. This can be used to perform low-level system actions.
Parameter | Description |
---|---|
command | command to execute |
stream | optional stream for capturing printed output |
Returns the result of the command.
On the Windows operating system the command output will be piped to a file stored in the system "ProgramData/Ultra Engine" directory. This file should be deleted if the command output contains any sensitive information.
local stream = CreateBufferStream()
Command("systeminfo | findstr /B /C:\"OS Name\"", stream)
while not stream:Eof() do
Print(stream:ReadLine())
end