summaryrefslogtreecommitdiff
path: root/.bashrc
blob: 4cbcbb68ba5a8171eb3df2b7520be5ba5761b5c5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
. ~/.shinit

# '>' is a nice prompt char because it need not be followed by a
# space.  It is easy to distinguish the command from the prompt.
#
# This satisfies both `shell-prompt-pattern' and `tramp-shell-prompt-pattern'.
PS1='$(exit_code=$?; test $exit_code -eq 0 \
    || printf %s $exit_code " ")${debian_chroot:+($debian_chroot)}\u@\h:\w>'

case "$TERM" in
    # if this is an xterm set its title to user@host:dir
    # (this doesn't stop the likes of ncmpcpp setting a title)
    xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h:\w\a\]\[\e[1m\]$PS1\[\e[0m\]"
	;;
    80-column|dumb|unknown) ;;
    *) PS1="\[\e[1m\]$PS1\[\e[0m\]" ;;
esac

[ -f /usr/share/bash-completion/bash_completion ] \
    && . /usr/share/bash-completion/bash_completion

# history settings
HISTCONTROL=ignorespace:ignoredups
HISTSIZE=5000
HISTFILESIZE=5000
HISTIGNORE=ls:pwd
shopt -s histappend