Modify Environment Variables in Ubuntu
April
17
In Ubuntu, environment variables should be defined (globally) in “/etc/environment”
Use your favorite text editor (in sudo) to modify the file
for example:
(command) sudo nano /etc/envrionment
Example File Contents:
PATH=”/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/genome/bin”
CONSED_HOME=”/usr/local/genome/bin”
To call the variable in terminal, prefix it with a “$”, in this case, I would do something like cd $CONSED_HOME, this will change directory to “/usr/local/genome/bin
To update the variables without rebooting, use the following command
source /etc/environment
From: http://stackoverflow.com/questions/2655641/set-environment-variable-in-ubuntu