Initial Commit
[safanaj_home.git] / .bashrc
blobff5f837a73f5793212f1d0b31f860ed58bd68f86
1 # ~/.bashrc: executed by bash(1) for non-login shells.
2 # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
3 # for examples
5 ## force source .profile ... BUGGY, FIX.
6 #[ x"$___BASH_PROFILE_IS_EXPORTED" != xyes ] && source ~/.bash_profile
8 # If not running interactively, don't do anything
9 [ -z "$PS1" ] && return
11 # don't put duplicate lines in the history. See bash(1) for more options
12 export HISTCONTROL=ignoredups
14 # check the window size after each command and, if necessary,
15 # update the values of LINES and COLUMNS.
16 shopt -s checkwinsize
18 # make less more friendly for non-text input files, see lesspipe(1)
19 [ -x /usr/bin/lesspipe ] && eval "$(lesspipe)"
21 # set variable identifying the chroot you work in (used in the prompt below)
22 if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
23     debian_chroot=$(cat /etc/debian_chroot)
26 # set a fancy prompt (non-color, unless we know we "want" color)
27 case "$TERM" in
28 xterm-color)
29     PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
30     ;;
32     PS1='${debian_chroot:+($debian_chroot)}\u:\w\$ '
33     ;;
34 esac
36 # Comment in the above and uncomment this below for a color prompt
37 PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
39 # If this is an xterm set the title to user@host:dir
40 case "$TERM" in
41 xterm*|rxvt*)
42     PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD/$HOME/~}\007"'
43     ;;
45     ;;
46 esac
48 # Alias definitions.
49 # You may want to put all your additions into a separate file like
50 # ~/.bash_aliases, instead of adding them here directly.
51 # See /usr/share/doc/bash-doc/examples in the bash-doc package.
52 if [ -f ~/.bash_aliases ]; then
53    . ~/.bash_aliases
55 # if [ -f ~/ALIAS ]; then
56 #     . ~/ALIAS
57 # fi
58 # I'm in X.
59 [ ! -z "$DISPLAY" ] && PS1='$ ' # && . ~/.xinitrc
61 # Enable color support of ls and also add handy aliases
62 if [ "$TERM" != "dumb" ]; then
63     eval "`dircolors -b`"
64     alias ls='ls --color=auto'
65     #alias dir='ls --color=auto --format=vertical'
66     #alias vdir='ls --color=auto --format=long'
69 [ "$EMACS" = "t" ] && alias ls='ls --color=none'
71 # enable programmable completion features (you don't need to enable
72 # this, if it's already enabled in /etc/bash.bashrc and /etc/profile
73 # sources /etc/bash.bashrc).
74 if [ -f /etc/bash_completion ]; then
75     . /etc/bash_completion