I've installed Matlab on my Ubuntu 18.04. Every time I want to open it I need to call it.
/usr/local/MATLAB/R2017a/bin/matlab
I think it is too long and waste of a little time. There has to be an easier way to open it. How can I open it simply by writing its name or is there any easier way?
You can either add
/usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.To do the second one follow the steps below.
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.)matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).Add the following lines to the
matlab
filematlab
file and make it executable.Add this to your
~/.bashrc
file