Hello Mariusz,
The equivalent of unix command is the command system
system('pwd')
system('emacs foo.sce');
The command you give is executed by a shell and thus depends on the OS you are using system("pwd") will not work on windows.
The spawn functions are different since they can be used to run
an executable and pass arguments to the executable like
spawn_sync(['emacs','-rv','foo.txt']) (emacs must ne in your
path).
spwan_sync runs the executable and wait for return from the
execution; spawn_async is asynchronous
and spawn can be used to run an executable (for example an
interpreter) and interact with the executable
through multiple commands (there's an exemple in
tests/transmit.sce).
Regards
jpc
I cannot find an equivalent of "unix" command (which executes the external program). I found something like "spawn" but its usage is not intuitive and I could not find documentation... How to run an external program from nsp script?Thanks in advance.
--
You received this message because you are subscribed to the Google Groups "tumbi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tumbi+un...@googlegroups.com.
To post to this group, send email to tu...@googlegroups.com.
Visit this group at https://groups.google.com/group/tumbi.
For more options, visit https://groups.google.com/d/optout.