proper place to set environment variables?

Hartmut Haase hha4491 at web.de
Tue May 13 11:20:36 CEST 2014


Hi John,
 >  ~/.profile
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.

# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022

# if running bash
if [ -n "$BASH_VERSION" ]; then
     # include .bashrc if it exists
     if [ -f "$HOME/.bashrc" ]; then
	. "$HOME/.bashrc"
     fi
fi

# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
     PATH="$HOME/bin:$PATH"
fi

This shows that if you are using bash, .bashrc will be sourced. So you 
put all your environment variables into .bashrc.
If you use a different shell you should modify ~/.profile so that the 
respective ...rc file will be sourced.
-- 
Viele Grüße,
Hartmut

Hungerhilfe: http://www.thehungersite.com

Ohne Zensur suchen:
http://suche.amnesty-bergedorf.de
Googeln ohne Google:
https://www.startpage.com/deu

Das heutige Motto:
Es gibt mehr Dinge zwischen Himmel und Erde als Deine Schulweisheit Dich 
träumen läßt.


More information about the Xfce mailing list