summaryrefslogtreecommitdiffstats
path: root/bashrc
diff options
context:
space:
mode:
authorGuillaume Rousse <guillomovitch@mandriva.org>2007-09-11 12:39:51 +0000
committerGuillaume Rousse <guillomovitch@mandriva.org>2007-09-11 12:39:51 +0000
commit25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d (patch)
tree9afa5ad3fecc7aca66222da768ba0245ae479d65 /bashrc
downloadsetup-25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d.tar
setup-25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d.tar.gz
setup-25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d.tar.bz2
setup-25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d.tar.xz
setup-25e03a3bb2c7bfbc1f3c177ee71c7f75683ebd9d.zip
move everything under trunk directory
Diffstat (limited to 'bashrc')
-rw-r--r--bashrc39
1 files changed, 39 insertions, 0 deletions
diff --git a/bashrc b/bashrc
new file mode 100644
index 0000000..9c50462
--- /dev/null
+++ b/bashrc
@@ -0,0 +1,39 @@
+# /etc/bashrc
+
+# System wide functions and aliases
+# Environment stuff goes in /etc/profile
+
+# by default, we want this to get set.
+# Even for non-interactive, non-login shells.
+if [ "`id -gn`" = "`id -un`" -a `id -u` -gt 99 ]; then
+ umask 002
+else
+ umask 022
+fi
+
+# are we an interactive shell?
+if [ "$PS1" ]; then
+ case $TERM in
+ xterm*)
+ PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
+ ;;
+ *)
+ ;;
+ esac
+ [ "$PS1" = "\\s-\\v\\\$ " ] && PS1="[\u@\h \W]\\$ "
+
+ if [ -z "$loginsh" ]; then # We're not a login shell
+ # Not all scripts in profile.d are compatible with other shells
+ # TODO: make the scripts compatible or check the running shell by
+ # themselves.
+ if [ -n "${BASH_VERSION}${KSH_VERSION}${ZSH_VERSION}" ]; then
+ for i in /etc/profile.d/*.sh; do
+ if [ -x $i ]; then
+ . $i
+ fi
+ done
+ fi
+ fi
+fi
+
+unset loginsh