Borrar filtros
Borrar filtros

Matlab open file in editor from the command line

2 visualizaciones (últimos 30 días)
Leo
Leo el 9 de Abr. de 2013
Respondida: Vishnu el 12 de Jul. de 2023
Hi there,
the linux shell script
%!/bin/bash
matlab -r "edit %1"
pretty much does what I want, but if matlab is already running, it will not open the file %1 in the editor of the running instance, but will start another instance of matlab.
How can I avoid starting another instance, if there's already one GUI running?

Respuestas (1)

Vishnu
Vishnu el 12 de Jul. de 2023
Hey @Leo I understand that you want to execute your script whitout opening other instance in using linux shell. I am soeey but currently matlab does not support this functionality however, you can try running the script in shell without opening gui by using :
$matlab -batch "edit %1"
Stack overflow link which might be helpfull, Stack Answer.

Categorías

Más información sobre Get Started with MATLAB en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by