Reputation: 611
command
export CLASSPATH=$CLASSPATH:/usr/share/java/mysql.jar
This sets the class path for terminal. If I close that terminal window and start a new terminal window, I currently have to fire command to set class path. I want to set it so it's permanent. How can I achieve this?
Upvotes: 0
Views: 372
Reputation: 2325
Set it in the bash file. It is found in /$HOME/.bashrc or /$HOME/.bash_profile
Put that line there:
//for all users
nano ~/.bashrc
//for current user
nano ~/.bash_profile
add that line and do CTRL + O to save and CTRL + X to exit Or just use your text editor to open the file
Upvotes: 2