]> ruderich.org/simon Gitweb - config/dotfiles.git/blob - bash/rc
*/rc: Move umask code from zsh/rc to shell/rc.
[config/dotfiles.git] / bash / rc
1 # Main bash configuration file.
2 #
3 # Is sourced by all interactive bash shells and other shells like scp or rcp.
4
5 # Copyright (C) 2011-2013  Simon Ruderich
6 #
7 # This file is free software: you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation, either version 3 of the License, or
10 # (at your option) any later version.
11 #
12 # This file is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with this file.  If not, see <http://www.gnu.org/licenses/>.
19
20
21 . ~/.shell/functions
22
23 source_debug ". ~/.bash/rc"
24
25 source_config ~/.shell/env
26
27
28 # Check if this is an interactive shell. Abort if not to prevent problems with
29 # scp and rcp. Taken from default Debian bashrc. Thanks.
30 if [[ $- != *i* ]]; then
31     return
32 fi
33
34
35 # Set the prompt; hostname and current working directory are displayed.
36 # Hostname is displayed in green, current directory in blue.
37 PS1='\[\033[01;32m\]\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\] \$ '
38
39 # Use Vi(m) style in bash.
40 set -o vi
41
42
43 source_config ~/.shell/aliases
44 source_config ~/.shell/rc
45
46 source_config ~/.bash/rc.local
47
48 source_debug ". ~/.bash/rc (done)"
49
50 # vim: ft=sh