I installed some programs in /opt/my-program/bin, I wanted to add /opt/my-program/bin to system $PATH for all users's non-login shell and login shell. What should I do?
Changing /etc/environment is OK for non-login shell, but it does not work for login shell because Debian's /etc/profile (which will be sourced by login shell) will override the $PATH specified in /etc/environment.
/usr/local/binwithout altering environment variables. – jordanm Oct 08 '12 at 06:53cd $(basedir "$0"). Symlinks cause$0changes. – Yang Bo Oct 08 '12 at 07:02/usr/local/binor~/bin. – Gilles 'SO- stop being evil' Oct 08 '12 at 22:56PATHin/etc/profile(at least for non-root users)? – Gilles 'SO- stop being evil' Oct 08 '12 at 22:57