3 # System wide environment and startup programs, for login setup
4 # Functions and aliases go in /etc/bashrc
6 # It's NOT a good idea to change this file unless you know what you
7 # are doing. It's much better to create a custom.sh shell script in
8 # /etc/profile.d/ to make custom changes to your environment, as this
9 # will prevent the need for merging in future updates.
16 if [ "$2" = "after" ] ; then
25 if [ -x /usr/bin/id ]; then
26 if [ -z "$EUID" ]; then
33 MAIL="/var/spool/mail/$USER"
37 if [ "$EUID" = "0" ]; then
39 pathmunge /usr/local/sbin
41 pathmunge /usr/local/sbin after
42 pathmunge /usr/sbin after
45 HOSTNAME=`/usr/bin/hostname 2>/dev/null`
47 if [ "$HISTCONTROL" = "ignorespace" ] ; then
48 export HISTCONTROL=ignoreboth
50 export HISTCONTROL=ignoredups
53 export PATH USER LOGNAME MAIL HOSTNAME HISTSIZE HISTCONTROL
55 # By default, we want umask to get set. This sets it for login shell
56 # Current threshold for system reserved uid/gids is 200
57 # You could check uidgid reservation validity in
58 # /usr/share/doc/setup-*/uidgid file
59 if [ $UID -gt 199 ] && [ "`id -gn`" = "`id -un`" ]; then
65 for i in /etc/profile.d/*.sh ; do
67 if [ "${-#*i}" != "$-" ]; then
70 . "$i" >/dev/null 2>&1