--- a/.bashrc Tue Apr 17 22:47:13 2018 +0300
+++ b/.bashrc Sun May 06 15:11:56 2018 +0300
@@ -9,15 +9,25 @@
. ~/.env
fi
-PS1='\n==============================================================================\r$?|\u@\h \w \nbash# '
+hr() {
+ local ruler=''
+ for (( i=${COLUMNS:-78}; i>0; i-=1 )) do
+ ruler+='='
+ done
+ echo $ruler
+}
+HR=`hr`
+
+PS1='\n'`hr`'\r$?|\u@\h \w \nbash# '
PS2='> '
case "$TERM" in
xterm*|eterm-color|screen|linux|cygwin)
- PS1=$'\n\e[36m==============================================================================\r$?|\e[31m\u\e[35m@\h\e[0m\e[36m \w \n\[\e[1m\e[31m\]bash#\[\e[0m\] '
+ PS1=$'\n\e[34m\e[1m'`hr`$'\r$?|\e[31m\u\e[35m@\h\e[0m\e[36m \w \n\[\e[1m\e[31m\]bash#\[\e[0m\] '
PS2=$'\[\e[32m\]> \[\e[0m\]'
;;
esac
+unset hr
# Set current directory in terminal emulator title.
case "$TERM" in
xterm*|screen|linux|cygwin)