bashrc: Merge-in new system file

This commit is contained in:
2022-08-16 14:18:25 +02:00
parent a2a1ec8c15
commit de97bb6bf4

13
bashrc
View File

@@ -16,7 +16,7 @@ if [ -z "$BASHRCSOURCED" ]; then
if [ "$PS1" ]; then if [ "$PS1" ]; then
if [ -z "$PROMPT_COMMAND" ]; then if [ -z "$PROMPT_COMMAND" ]; then
case $TERM in case $TERM in
xterm*|vte*) xterm*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
else else
@@ -64,15 +64,8 @@ if [ -z "$BASHRCSOURCED" ]; then
esac esac
} }
# By default, we want umask to get set. This sets it for non-login shell. # Set default umask for non-login shell only if it is set to 0
# Current threshold for system reserved uid/gids is 200 [ `umask` -eq 0 ] && umask 022
# You could check uidgid reservation validity in
# /usr/share/doc/setup-*/uidgid file
if [ $UID -gt 199 ] && [ "`/usr/bin/id -gn`" = "`/usr/bin/id -un`" ]; then
umask 002
else
umask 022
fi
SHELL=/bin/bash SHELL=/bin/bash
# Only display echos from profile.d scripts if we are no login shell # Only display echos from profile.d scripts if we are no login shell