You are not logged in.
Dear Community,
I would like to create a package for a MATLAB toolbox. In order for MATLAB to pick it up, some folders of the toolbox need to be added to MATLAB's path. One way to achieve this is by appending them to the MATLABPATH environment variable.
My package writes a shell script into /etc/profile.d that does just that. However, it only gets sourced at the next login or when the user manually sources it.
Is there any way to make this happen automatically after installing a package? Or is the only possible solution to echo an instruction to the user with the source command that has to be executed?
Thank you!
Offline
There is no way to set a variable for the current session from a package.
Online
Is it not possible to put those files in a path that matlab reads by default?
| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |
Offline
Well, there is matlabrc (https://de.mathworks.com/help/matlab/ref/matlabrc.html), but it is in the MATLAB installation directory, so for that I would need to locate where MATLAB is installed. If it is installed into the directory where the matlab AUR package puts it, or it is on the PATH, it's fine, but it would be nice to have something more generic.
Offline