Code: Select all
RUN("/bin/dash", "/tmp/script")
cmd-1
cmd-2
All fine so far.
Now I want to get rid of the extra script file. The dash shell can input commands as an argument. Instead of passing the file name
/bin/dash /tmp/script
one can also pass the file content as argument like
/bin/dash -c 'cmd-1 ; cmd-2'
This works in a terminal. But transfering to my application code
Code: Select all
VAR r = RUN("/bin/dash", "-c 'cmd-1 ; cmd-2'")
Why is executing dash from FB code working with the script file argument, but isn't working with -c option?
Thanks in advance!
PS: FreeBASIC Compiler - Version 1.05.0 (09-21-2018), built for linux-arm (32bit)