Update Path Externally

2 vues (au cours des 30 derniers jours)
Cesare
Cesare le 13 Avr 2011
Is there a way to add a folder to the Matlab Path without opening Matlab? E.g. if I want to create an installer for a new toolbox so that the user does not have to manually modify the path. Thanks in advance, Cesare

Réponses (3)

Fangjun Jiang
Fangjun Jiang le 13 Avr 2011
edit pathdef.m

Kaustubha Govind
Kaustubha Govind le 21 Avr 2011
If you don't mind MATLAB performing this operation silently, you could use the following system command (MATLAB must be on path):
matlab -nodisplay -nosplash -r "addpath('/path/to/add'); savepath; quit;"
For Windows, see Solution#1-16B8X

Cesare
Cesare le 19 Avr 2011
I was a bit scared of the big warning telling not to edit it.
  1 commentaire
Fangjun Jiang
Fangjun Jiang le 21 Avr 2011
Not if you do it right.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Startup and Shutdown dans Help Center et File Exchange

Tags

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by