cp /etc/profile /etc/profile.back
sudo vim /etc/profile
export PATH="$PATH:[自己要添加的path1]:[自己要添加的变量2]"或export CLASS="[自己要添加的path]"
export PATH="$PATH:$CLASS"
source /etc/profile
deepin添加环境变量
原文:http://www.cnblogs.com/super-age/p/6804336.html