UPDATE: from here
~/.bash_rc is not read by any program, and
~/.bashrc is the configuration file of interactive instances of bash. You should not define environment variables in
~/.bashrc. The right place to define environment variables such as
~/.bash_profile if you don’t care about shells other than bash).
Just type the the following command in the terminal ant it will work temporarily
So if I have a program called a.out located in /home/user/Desktop/MyProgram/, I would type:
To make it permanent, add the same line to the file ~/.bashrc .