aboutsummaryrefslogtreecommitdiffstats
path: root/bash_include
diff options
context:
space:
mode:
authorTing-Wei Lan <lantw44@gmail.com>2014-06-10 02:42:02 +0800
committerTing-Wei Lan <lantw44@gmail.com>2014-06-10 02:42:02 +0800
commit2e2abd1361760c2037ec75f644cf75ef54943f7b (patch)
tree12b9eee671bdc0587ffbb770e4b41c300bdd7b70 /bash_include
parentb1d5d4d47783cdd471b4cc6eb7c46b3b4ba91761 (diff)
downloadconfigfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar.gz
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar.bz2
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar.lz
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar.xz
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.tar.zst
configfile-2e2abd1361760c2037ec75f644cf75ef54943f7b.zip
bash_include: 在 PS1 顯示背景工作數量和 Android 提示bash_include-20140610
Diffstat (limited to 'bash_include')
-rw-r--r--bash_include16
1 files changed, 11 insertions, 5 deletions
diff --git a/bash_include b/bash_include
index 67cea7e..261bb53 100644
--- a/bash_include
+++ b/bash_include
@@ -35,8 +35,8 @@ if [[ "$-" == *i* ]] ; then interactive_shell=1; fi
# Internal Variables
-colorprompting='\[\e[1;31m\]\!\[\e[m\] \[\e[35m\]$tty_short\[\e[m\][\[\e[1;33m\]\u\[\e[m\]@\[\e[1;32m\]\h\[\e[m\] \[\e[1;36m\]\w\[\e[m\]]'
-nocolorprompting='\! $tty_short[\u@\h \w]'
+colorprompting='\[\e[1;31m\]\!\[\e[m\] \[\e[35m\]$tty_short\[\e[m\][\[\e[1;33m\]\u\[\e[m\]@\[\e[1;32m\]\h\[\e[m\] \[\e[1;36m\]\w\[\e[m\]]\[\e[44;37m\] \j \[\e[m\]'
+nocolorprompting='\! $tty_short[\u@\h \w] \j '
if [ "$SSH_CONNECTION" ]
then
@@ -44,16 +44,22 @@ then
nocolorprompting="*$nocolorprompting"
fi
+if [ "$EPREFIX" ]
+then
+ colorprompting="$colorprompting[\[\e[1;35m\]Prefix\[\e[m\]]"
+ nocolorprompting="$nocolorprompting[Prefix]"
+fi
+
if [ "$UNDER_JHBUILD" = "true" ] || [ "$CERTIFIED_GNOMIE" = "yes" ]
then
colorprompting="$colorprompting[\[\e[1;35m\]JHBuild\[\e[m\]]"
nocolorprompting="$nocolorprompting[JHBuild]"
fi
-if [ "$EPREFIX" ]
+if [ "$ANDROID_BUILD_TOP" ]
then
- colorprompting="$colorprompting[\[\e[1;35m\]Prefix\[\e[m\]]"
- nocolorprompting="$nocolorprompting[Prefix]"
+ colorprompting="$colorprompting[\[\e[1;35m\]Android\[\e[m\]]"
+ nocolorprompting="$nocolorprompting[Android]"
fi
if [ -f "$HOME/.bash_addps" ]