Virtual Environment Manager for MATLAB
Version 1.0.0 (2,48 KB) von
Mitchell Tillman
Manages MATLAB path in similar fashion as Python virtual environments.
When working with different versions of identically named functions located in different folders, it can quickly become confusing which version of a function is being called. Use "envMan" to add and remove paths according to which function is being called, rather than manual methods such as "which". This mimics how Python manages virtual environments.
Recommended usage:
- Call envMan('-r',folderPath) to register a folder (and its subfolders) containing one version. This path is stored in a "envPaths.mat" file in your userpath directory.
- In a .m file within the "folderPath" folder, call envMan('-s',folderPath). Thus, when running that .m file, you will ensure that only the appropriate versions are on the MATLAB search path.
- Repeat steps 1 & 2 for each "folderPath" folder that you want to serve as a siloed virtual environment.
- When running the .m file containing the envMan call, the specified "folderPath" will be added to the path. The other registered environments will be removed from the path. Unregistered paths on the search path (not located within a "folderPath" folder) will not be affected.
Zitieren als
Mitchell Tillman (2024). Virtual Environment Manager for MATLAB (https://www.mathworks.com/matlabcentral/fileexchange/123805-virtual-environment-manager-for-matlab), MATLAB Central File Exchange. Abgerufen.
Kompatibilität der MATLAB-Version
Erstellt mit
R2021b
Kompatibel mit R2019b und späteren Versionen
Plattform-Kompatibilität
Windows macOS LinuxTags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
1.0.0 |