core/bash/system.bashrc

24 lines
613 B
Plaintext
Raw Normal View History

2010-03-13 23:25:19 +08:00
#
# /etc/bash.bashrc
#
2011-04-23 00:44:32 +08:00
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
2010-03-13 23:25:19 +08:00
PS1='[\u@\h \W]\$ '
PS2='> '
PS3='> '
PS4='+ '
2011-04-23 00:44:32 +08:00
case ${TERM} in
xterm*|rxvt*|Eterm|aterm|kterm|gnome*)
PROMPT_COMMAND=${PROMPT_COMMAND:+$PROMPT_COMMAND; }'printf "\033]0;%s@%s:%s\007" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
;;
screen)
PROMPT_COMMAND=${PROMPT_COMMAND:+$PROMPT_COMMAND; }'printf "\033_%s@%s:%s\033\\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
;;
esac
2010-03-13 23:25:19 +08:00
[ -r /etc/bash_completion ] && . /etc/bash_completion