Reputation: 3
For example,
!vim
in iPython opens vim. Is there such a thing in Octave?
Upvotes: 0
Views: 253
Reputation: 13091
If you only want to run another process then , the already suggested system()
or exec()
should work.
However, if you plan on using this to simply open up a text editor and edit an Octave file, set the value of EDITOR with EDITOR ("vim")
(you can add this to your .octaverc
file) and then use edit (foo)
to open up the foo function on the text editor.
Upvotes: 1
Reputation: 16096
The following might work system("vim");
If you want the interactivity of calling something inside of Octave and interactivity with it directly try exec("vim")
instead.
See Controlling Subprocesses for more examples.
Otherwise you can either combine calls to system
, fork
and exec
or extend octave with Python/iPython or C++.
Upvotes: 1