summaryrefslogtreecommitdiff
path: root/.bashrc
diff options
context:
space:
mode:
authorMike Crute <crutem@amazon.com>2019-05-23 15:10:00 +0200
committerMike Crute <crutem@amazon.com>2019-05-23 15:10:17 +0200
commitd976de5ab2d2755e595b1bfd1a8d7bf079de2c1d (patch)
tree6959f6883fae4903908576610f8d6d0ce886afc9 /.bashrc
parentfcc6363c58e8768a766639c3e4dfc33ac9a11c77 (diff)
downloaddotfiles-d976de5ab2d2755e595b1bfd1a8d7bf079de2c1d.tar.bz2
dotfiles-d976de5ab2d2755e595b1bfd1a8d7bf079de2c1d.tar.xz
dotfiles-d976de5ab2d2755e595b1bfd1a8d7bf079de2c1d.zip
Colorful prompt
Diffstat (limited to '.bashrc')
-rw-r--r--.bashrc13
1 files changed, 10 insertions, 3 deletions
diff --git a/.bashrc b/.bashrc
index 3246c0d..23e7e84 100644
--- a/.bashrc
+++ b/.bashrc
@@ -113,9 +113,16 @@ if [[ "$MY_SHELL" =~ "bash" ]]; then
113 113
114 export PROMPT_COMMAND="history -a" 114 export PROMPT_COMMAND="history -a"
115 115
116 # Cache this instead of using \h to avoid the hostname lookup 116 # Cache user and host instead of using \h and \u to avoid the hostname and
117 # on every line. This can be really slow on a slow connection. 117 # username lookup on every line. This can be really slow on a slow
118 export PS1="\t \u@$(hostname -s) \W \$ " 118 # connection or on systems running SSSD.
119
120 # Old simple version
121 #export PS1="\t $(whoami)@$(hostname -s) \W \$ "
122
123 # Colorful version (colors are for my normal stterm scheme, not ASCII)
124 [[ $UID == 0 ]]; _pcolor="91" || _pcolor="92"
125 export PS1="\t \[\e[${_pcolor};1;49m\]$(whoami)@$(hostname -s) \W \[\e[33;1;49m\]$ \[\e[39;0;49m\]"
119 126
120 load_all_from "$HOME/.bash_completion.d" 127 load_all_from "$HOME/.bash_completion.d"
121 128