I have a shell script on a mac (OSX 10.9) named msii810161816_TMP_CMD with the following content.
matlab
When I execute it, I get
By default, aliases are not expanded in non-interactive shells, which is what shell scripts are. Aliases are intended to be used by a person at the keyboard as a typing aid.
If your goal is to not have to type the full path to matlab
, instead of creating an alias you should modify your $PATH
. Add /Applications/MATLAB_R2014a.app/bin
to your $PATH environment variable and then both you and your shell scripts will be able to simply say
matlab