X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=bashrc;h=5ef300fb445ea311b3f75044796ac68387864520;hb=0c16d439bb43a94d33b3d50d780ea755db57c860;hp=eff48e131df2e2f9d686b2580ffdb7a243852aa6;hpb=e7042582c0611d0da7964d83549ce776ee0d7956;p=packages%2Fbash.git diff --git a/bashrc b/bashrc index eff48e1..5ef300f 100644 --- a/bashrc +++ b/bashrc @@ -3,17 +3,23 @@ # System wide functions and aliases # Environment stuff goes in /etc/profile +# Test for an interactive shell. There is no need to set anything +# past this point for scp and rcp, and it's important to refrain from +# outputting anything in those cases. +if [[ $- != *i* ]] ; then + # Shell is non-interactive. Be done now! + return +fi + # If this is an xterm set the title to user@host:dir case $TERM in - gnome|nxterm|xterm*|rxvt*) + gnome*|nxterm|xterm*|rxvt*|konsole*) PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"' ;; *) ;; esac - PS1="[\u@\h \W]\\$ " -export PS1 alias which="type -p"