]> git.phdru.name Git - dotfiles.git/commitdiff
.bash_prompt: add dim colors
authorOleg Broytman <phd@phdru.name>
Wed, 24 Feb 2016 10:29:23 +0000 (13:29 +0300)
committerOleg Broytman <phd@phdru.name>
Wed, 24 Feb 2016 10:29:23 +0000 (13:29 +0300)
.bash_prompt

index f7ae3bbd991b41a40f4d9fc712d7dc0ca68d5808..f2c3655e42ff337385a74eb44a2b96bb6d1ce741 100644 (file)
@@ -67,6 +67,7 @@ set_prompts() {
     local blue=""
     local bold=""
     local cyan=""
+    local dim=""
     local green=""
     local orange=""
     local purple=""
@@ -75,6 +76,17 @@ set_prompts() {
     local white=""
     local yellow=""
 
+    local dim_black=""
+    local dim_blue=""
+    local dim_bold=""
+    local dim_cyan=""
+    local dim_green=""
+    local dim_orange=""
+    local dim_magenta=""
+    local dim_red=""
+    local dim_white=""
+    local dim_yellow=""
+
     local hostStyle=""
     local userStyle=""
 
@@ -82,6 +94,7 @@ set_prompts() {
         tput sgr0 # reset colors
 
         bold=$(tput bold)
+        dim=$(tput dim)
         reset=$(tput sgr0)
 
         # Solarized colors
@@ -95,8 +108,19 @@ set_prompts() {
         red=$(tput setaf 124)
         white=$(tput setaf 15)
         yellow=$(tput setaf 136)
+
+        dim_black=$dim$black
+        dim_blue=$dim$blue
+        dim_cyan=$dim$cyan
+        dim_green=$dim$green
+        dim_orange=$dim$orange
+        dim_magenta=$dim$magenta
+        dim_red=$dim$red
+        dim_white=$dim$white
+        dim_yellow=$dim$yellow
     else
         bold=""
+        dim=""
         reset="\e[0m"
 
         black="\e[1;30m"
@@ -108,6 +132,16 @@ set_prompts() {
         red="\e[1;31m"
         white="\e[1;37m"
         yellow="\e[1;33m"
+
+        dim_black="\e[1;30m"
+        dim_blue="\e[1;34m"
+        dim_cyan="\e[1;36m"
+        dim_green="\e[1;32m"
+        dim_orange="\e[1;33m"
+        dim_magenta="\e[1;35m"
+        dim_red="\e[1;31m"
+        dim_white="\e[1;37m"
+        dim_yellow="\e[1;33m"
     fi
 
     # build the prompt